diff options
author | Florian Diebold <[email protected]> | 2019-12-25 14:00:10 +0000 |
---|---|---|
committer | Florian Diebold <[email protected]> | 2019-12-26 15:23:40 +0000 |
commit | 8ac25f119eb45d425370d9f7f093bc206e6c4a9f (patch) | |
tree | 7a9bcbcb2c46a549baa7a411a99cd7c9eb39423d /crates/ra_hir_def/src/body | |
parent | 79c90b5641d2934864c587380e4f050ab63ac029 (diff) |
Keep track of visibility during def collection
Diffstat (limited to 'crates/ra_hir_def/src/body')
-rw-r--r-- | crates/ra_hir_def/src/body/lower.rs | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/crates/ra_hir_def/src/body/lower.rs b/crates/ra_hir_def/src/body/lower.rs index 5323af097..88c4a1216 100644 --- a/crates/ra_hir_def/src/body/lower.rs +++ b/crates/ra_hir_def/src/body/lower.rs | |||
@@ -543,7 +543,10 @@ where | |||
543 | }; | 543 | }; |
544 | self.body.item_scope.define_def(def); | 544 | self.body.item_scope.define_def(def); |
545 | if let Some(name) = name { | 545 | if let Some(name) = name { |
546 | self.body.item_scope.push_res(name.as_name(), def.into()); | 546 | let vis = crate::visibility::ResolvedVisibility::Public; // FIXME determine correctly |
547 | self.body | ||
548 | .item_scope | ||
549 | .push_res(name.as_name(), crate::per_ns::PerNs::from_def(def, vis)); | ||
547 | } | 550 | } |
548 | } | 551 | } |
549 | } | 552 | } |