aboutsummaryrefslogtreecommitdiff
path: root/crates/hir_def/src/nameres.rs
diff options
context:
space:
mode:
Diffstat (limited to 'crates/hir_def/src/nameres.rs')
-rw-r--r--crates/hir_def/src/nameres.rs11
1 files changed, 11 insertions, 0 deletions
diff --git a/crates/hir_def/src/nameres.rs b/crates/hir_def/src/nameres.rs
index 9e8e4e9ec..6a09ad420 100644
--- a/crates/hir_def/src/nameres.rs
+++ b/crates/hir_def/src/nameres.rs
@@ -409,6 +409,17 @@ impl DefMap {
409 } 409 }
410 } 410 }
411 } 411 }
412
413 fn shrink_to_fit(&mut self) {
414 self.extern_prelude.shrink_to_fit();
415 self.exported_proc_macros.shrink_to_fit();
416 self.diagnostics.shrink_to_fit();
417 self.modules.shrink_to_fit();
418 for (_, module) in self.modules.iter_mut() {
419 module.children.shrink_to_fit();
420 module.scope.shrink_to_fit();
421 }
422 }
412} 423}
413 424
414impl ModuleData { 425impl ModuleData {