diff options
Diffstat (limited to 'crates/ra_analysis/src')
-rw-r--r-- | crates/ra_analysis/src/imp.rs | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/crates/ra_analysis/src/imp.rs b/crates/ra_analysis/src/imp.rs index 843f28d05..0de0e2645 100644 --- a/crates/ra_analysis/src/imp.rs +++ b/crates/ra_analysis/src/imp.rs | |||
@@ -43,7 +43,7 @@ impl AnalysisHostImpl { | |||
43 | } | 43 | } |
44 | pub fn apply_change(&mut self, change: AnalysisChange) { | 44 | pub fn apply_change(&mut self, change: AnalysisChange) { |
45 | log::info!("apply_change {:?}", change); | 45 | log::info!("apply_change {:?}", change); |
46 | self.gc_syntax_trees(); | 46 | // self.gc_syntax_trees(); |
47 | 47 | ||
48 | for (file_id, text) in change.files_changed { | 48 | for (file_id, text) in change.files_changed { |
49 | self.db | 49 | self.db |
@@ -117,6 +117,10 @@ impl AnalysisHostImpl { | |||
117 | } | 117 | } |
118 | } | 118 | } |
119 | 119 | ||
120 | #[allow(unused)] | ||
121 | /// Ideally, we should call this function from time to time to collect heavy | ||
122 | /// syntax trees. However, if we actually do that, everything is recomputed | ||
123 | /// for some reason. Needs investigation. | ||
120 | fn gc_syntax_trees(&mut self) { | 124 | fn gc_syntax_trees(&mut self) { |
121 | self.db | 125 | self.db |
122 | .query(ra_db::SourceFileQuery) | 126 | .query(ra_db::SourceFileQuery) |