From: vibhatsu <[email protected]>
In full constructor, add initialization for ExternalItem base class. Use
the node id inside ExternalItem to populate member node id.
gcc/rust/ChangeLog:
* ast/rust-macro.h: add initialization for ExternalItem base
class in full construtor and use node id inside ExternalItem
to populate memeber node id.
Signed-off-by: vibhatsu <[email protected]>
---
This change was merged into the gccrs repository and is posted here for
upstream visibility and potential drive-by review, as requested by GCC
release managers.
Each commit email contains a link to its details on github from where you can
find the Pull-Request and associated discussions.
Commit on github:
https://github.com/Rust-GCC/gccrs/commit/0cc6e9cf4603e5d539266abf7b3dbb2c77a74966
The commit has been mentioned in the following pull-request(s):
- https://github.com/Rust-GCC/gccrs/pull/4423
gcc/rust/ast/rust-macro.h | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/gcc/rust/ast/rust-macro.h b/gcc/rust/ast/rust-macro.h
index 0342800f2..c68ba27b0 100644
--- a/gcc/rust/ast/rust-macro.h
+++ b/gcc/rust/ast/rust-macro.h
@@ -709,8 +709,10 @@ private:
MacroInvocData invoc_data, std::vector<Attribute> outer_attrs,
location_t locus, bool is_semi_coloned,
std::vector<std::unique_ptr<MacroInvocation>> &&pending_eager_invocs)
- : TraitItem (locus), outer_attrs (std::move (outer_attrs)), locus (locus),
- node_id (Analysis::Mappings::get ().get_next_node_id ()),
+ : TraitItem (locus),
+ ExternalItem (Analysis::Mappings::get ().get_next_node_id ()),
+ outer_attrs (std::move (outer_attrs)), locus (locus),
+ node_id (ExternalItem::get_node_id ()),
invoc_data (std::move (invoc_data)), is_semi_coloned (is_semi_coloned),
kind (kind), builtin_kind (builtin_kind),
pending_eager_invocs (std::move (pending_eager_invocs))
--
2.53.0