aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorOwen Avery <powerboat9.gamer@gmail.com>2023-09-04 14:09:10 -0400
committerCohenArthur <arthur.cohen@embecosm.com>2023-09-07 06:33:01 +0000
commite1d0b3cc02826bf6f2224434c6a1c46c0bb03d0b (patch)
tree1fea42ee2785b49e171287c1a4b42438ff947545 /gcc
parent4e7ae3938b2364370e848acb3d51e1a9c4c5d512 (diff)
downloadgcc-e1d0b3cc02826bf6f2224434c6a1c46c0bb03d0b.zip
gcc-e1d0b3cc02826bf6f2224434c6a1c46c0bb03d0b.tar.gz
gcc-e1d0b3cc02826bf6f2224434c6a1c46c0bb03d0b.tar.bz2
Remove Gcc_backend
gcc/rust/ChangeLog: * rust-backend.h (Backend::Backend): New. (Backend::~Backend): Remove. (class Gcc_backend): Remove. * rust-gcc.cc (Gcc_backend::Gcc_backend): Rename to ... (Backend::Backend): ... here. (rust_get_backend): Construct Backend instead of Gcc_backend. Signed-off-by: Owen Avery <powerboat9.gamer@gmail.com>
Diffstat (limited to 'gcc')
-rw-r--r--gcc/rust/rust-backend.h8
-rw-r--r--gcc/rust/rust-gcc.cc4
2 files changed, 3 insertions, 9 deletions
diff --git a/gcc/rust/rust-backend.h b/gcc/rust/rust-backend.h
index 9f12273..e2857f7 100644
--- a/gcc/rust/rust-backend.h
+++ b/gcc/rust/rust-backend.h
@@ -43,7 +43,7 @@ class Bvariable;
class Backend
{
public:
- virtual ~Backend () {}
+ Backend ();
// Name/type/location. Used for function parameters, struct fields,
// interface methods.
@@ -466,10 +466,4 @@ protected:
tree convert_tree (tree, tree, location_t);
};
-class Gcc_backend : public Backend
-{
-public:
- Gcc_backend ();
-};
-
#endif // RUST_BACKEND_H
diff --git a/gcc/rust/rust-gcc.cc b/gcc/rust/rust-gcc.cc
index 45ae1d5..ef7bd9c 100644
--- a/gcc/rust/rust-gcc.cc
+++ b/gcc/rust/rust-gcc.cc
@@ -99,7 +99,7 @@ get_identifier_from_string (const std::string &str)
// Define the built-in functions that are exposed to GCCRust.
-Gcc_backend::Gcc_backend ()
+Backend::Backend ()
{
/* We need to define the fetch_and_add functions, since we use them
for ++ and --. */
@@ -2474,5 +2474,5 @@ Backend::write_global_definitions (
Backend *
rust_get_backend ()
{
- return new Gcc_backend ();
+ return new Backend ();
}