aboutsummaryrefslogtreecommitdiff
path: root/gcc/rust/resolve/rust-name-resolution-context.h
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/rust/resolve/rust-name-resolution-context.h')
-rw-r--r--gcc/rust/resolve/rust-name-resolution-context.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/gcc/rust/resolve/rust-name-resolution-context.h b/gcc/rust/resolve/rust-name-resolution-context.h
index bd03ff9..19b9436 100644
--- a/gcc/rust/resolve/rust-name-resolution-context.h
+++ b/gcc/rust/resolve/rust-name-resolution-context.h
@@ -222,9 +222,9 @@ public:
{
std::function<void (const S &, NodeId)> insert_segment_resolution
= [this] (const S &seg, NodeId id) {
- if (resolved_nodes.find (Usage (seg.get_node_id ()))
- == resolved_nodes.end ())
- map_usage (Usage (seg.get_node_id ()), Definition (id));
+ auto seg_id = unwrap_segment_node_id (seg);
+ if (resolved_nodes.find (Usage (seg_id)) == resolved_nodes.end ())
+ map_usage (Usage (seg_id), Definition (id));
};
switch (ns)
{