diff options
Diffstat (limited to 'crates/ra_hir/src/resolve.rs')
-rw-r--r-- | crates/ra_hir/src/resolve.rs | 16 |
1 files changed, 7 insertions, 9 deletions
diff --git a/crates/ra_hir/src/resolve.rs b/crates/ra_hir/src/resolve.rs index 871f7d8f7..3e0af3a43 100644 --- a/crates/ra_hir/src/resolve.rs +++ b/crates/ra_hir/src/resolve.rs | |||
@@ -109,8 +109,6 @@ impl Resolver { | |||
109 | self.scopes.iter().rev().find_map(|scope| match scope { | 109 | self.scopes.iter().rev().find_map(|scope| match scope { |
110 | Scope::ModuleScope(m) => Some((&*m.item_map, m.module.clone())), | 110 | Scope::ModuleScope(m) => Some((&*m.item_map, m.module.clone())), |
111 | 111 | ||
112 | Scope::ModuleScopeRef(m) => Some((m.item_map, m.module.clone())), | ||
113 | |||
114 | _ => None, | 112 | _ => None, |
115 | }) | 113 | }) |
116 | } | 114 | } |
@@ -197,13 +195,13 @@ impl Scope { | |||
197 | fn collect_names(&self, f: &mut FnMut(Name, PerNs<Resolution>)) { | 195 | fn collect_names(&self, f: &mut FnMut(Name, PerNs<Resolution>)) { |
198 | match self { | 196 | match self { |
199 | Scope::ModuleScope(m) => { | 197 | Scope::ModuleScope(m) => { |
200 | m.item_map[m.module.module_id] | 198 | // TODO: should we provide `self` here? |
201 | .entries() | 199 | // f( |
202 | .for_each(|(name, res)| { | 200 | // Name::self_param(), |
203 | f(name.clone(), res.def.map(|def| Resolution::Def { def })); | 201 | // PerNs::types(Resolution::Def { |
204 | }) | 202 | // def: m.module.into(), |
205 | } | 203 | // }), |
206 | Scope::ModuleScopeRef(m) => { | 204 | // ); |
207 | m.item_map[m.module.module_id] | 205 | m.item_map[m.module.module_id] |
208 | .entries() | 206 | .entries() |
209 | .for_each(|(name, res)| { | 207 | .for_each(|(name, res)| { |