diff options
author | Owen Avery <powerboat9.gamer@gmail.com> | 2023-08-19 13:13:21 -0400 |
---|---|---|
committer | Philip Herron <philip.herron@embecosm.com> | 2023-08-23 13:24:24 +0000 |
commit | c727e23596ad62b441b9dea655b13f62caf74092 (patch) | |
tree | 04601fd7aacbed085b36a5fd4913698757317538 /gcc/rust/backend/rust-tree.cc | |
parent | 4baf8ab8f218c2c7c6c3e04f0ee2a09a2ae1165e (diff) | |
download | gcc-c727e23596ad62b441b9dea655b13f62caf74092.zip gcc-c727e23596ad62b441b9dea655b13f62caf74092.tar.gz gcc-c727e23596ad62b441b9dea655b13f62caf74092.tar.bz2 |
Namespace related tweaks
gcc/rust/ChangeLog:
* backend/rust-tree.cc
(Rust::gt_pch_nx): Move external function declaration ...
(gt_pch_nx): ... out of Rust namespace.
* backend/rust-tree.h
(OVL_FIRST): Qualify function name.
Signed-off-by: Owen Avery <powerboat9.gamer@gmail.com>
Diffstat (limited to 'gcc/rust/backend/rust-tree.cc')
-rw-r--r-- | gcc/rust/backend/rust-tree.cc | 19 |
1 files changed, 12 insertions, 7 deletions
diff --git a/gcc/rust/backend/rust-tree.cc b/gcc/rust/backend/rust-tree.cc index de79a02..a276af8 100644 --- a/gcc/rust/backend/rust-tree.cc +++ b/gcc/rust/backend/rust-tree.cc @@ -4249,6 +4249,17 @@ struct GTY ((for_user)) source_location_table_entry tree var; }; +// exit/reenter namespace to declare some external functions + +} // namespace Rust + +extern void +gt_pch_nx (Rust::source_location_table_entry &); +extern void +gt_pch_nx (Rust::source_location_table_entry *, gt_pointer_operator, void *); + +namespace Rust { + /* Traits class for function start hash maps below. */ struct source_location_table_entry_hash @@ -4299,17 +4310,11 @@ struct source_location_table_entry_hash && ref.var == NULL_TREE); } - static void pch_nx (source_location_table_entry &p) - { - extern void gt_pch_nx (source_location_table_entry &); - gt_pch_nx (p); - } + static void pch_nx (source_location_table_entry &p) { gt_pch_nx (p); } static void pch_nx (source_location_table_entry &p, gt_pointer_operator op, void *cookie) { - extern void gt_pch_nx (source_location_table_entry *, gt_pointer_operator, - void *); gt_pch_nx (&p, op, cookie); } }; |