diff options
Diffstat (limited to 'crates/ra_hir_def/src/nameres')
-rw-r--r-- | crates/ra_hir_def/src/nameres/collector.rs | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/crates/ra_hir_def/src/nameres/collector.rs b/crates/ra_hir_def/src/nameres/collector.rs index 08693cb13..252178b6b 100644 --- a/crates/ra_hir_def/src/nameres/collector.rs +++ b/crates/ra_hir_def/src/nameres/collector.rs | |||
@@ -352,10 +352,10 @@ where | |||
352 | 352 | ||
353 | self.update(module_id, Some(import_id), &items); | 353 | self.update(module_id, Some(import_id), &items); |
354 | // record the glob import in case we add further items | 354 | // record the glob import in case we add further items |
355 | self.glob_imports | 355 | let glob = self.glob_imports.entry(m.local_id).or_default(); |
356 | .entry(m.local_id) | 356 | if !glob.iter().any(|it| *it == (module_id, import_id)) { |
357 | .or_default() | 357 | glob.push((module_id, import_id)); |
358 | .push((module_id, import_id)); | 358 | } |
359 | } | 359 | } |
360 | } | 360 | } |
361 | Some(ModuleDefId::AdtId(AdtId::EnumId(e))) => { | 361 | Some(ModuleDefId::AdtId(AdtId::EnumId(e))) => { |