aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_ide/src/references
diff options
context:
space:
mode:
Diffstat (limited to 'crates/ra_ide/src/references')
-rw-r--r--crates/ra_ide/src/references/rename.rs2
-rw-r--r--crates/ra_ide/src/references/search_scope.rs5
2 files changed, 1 insertions, 6 deletions
diff --git a/crates/ra_ide/src/references/rename.rs b/crates/ra_ide/src/references/rename.rs
index 1abf20215..b804d5f6d 100644
--- a/crates/ra_ide/src/references/rename.rs
+++ b/crates/ra_ide/src/references/rename.rs
@@ -88,7 +88,7 @@ fn rename_mod(
88 file_system_edits.push(move_file); 88 file_system_edits.push(move_file);
89 } 89 }
90 } 90 }
91 ModuleSource::Module(..) | ModuleSource::Block(..) => {} 91 ModuleSource::Module(..) => {}
92 } 92 }
93 } 93 }
94 94
diff --git a/crates/ra_ide/src/references/search_scope.rs b/crates/ra_ide/src/references/search_scope.rs
index 92eb2015b..f5c9589f4 100644
--- a/crates/ra_ide/src/references/search_scope.rs
+++ b/crates/ra_ide/src/references/search_scope.rs
@@ -96,10 +96,6 @@ impl NameDefinition {
96 let range = Some(m.syntax().text_range()); 96 let range = Some(m.syntax().text_range());
97 res.insert(file_id, range); 97 res.insert(file_id, range);
98 } 98 }
99 ModuleSource::Block(b) => {
100 let range = Some(b.syntax().text_range());
101 res.insert(file_id, range);
102 }
103 ModuleSource::SourceFile(_) => { 99 ModuleSource::SourceFile(_) => {
104 res.insert(file_id, None); 100 res.insert(file_id, None);
105 res.extend(parent_module.children(db).map(|m| { 101 res.extend(parent_module.children(db).map(|m| {
@@ -141,7 +137,6 @@ impl NameDefinition {
141 let mut res = FxHashMap::default(); 137 let mut res = FxHashMap::default();
142 let range = match module_src.value { 138 let range = match module_src.value {
143 ModuleSource::Module(m) => Some(m.syntax().text_range()), 139 ModuleSource::Module(m) => Some(m.syntax().text_range()),
144 ModuleSource::Block(b) => Some(b.syntax().text_range()),
145 ModuleSource::SourceFile(_) => None, 140 ModuleSource::SourceFile(_) => None,
146 }; 141 };
147 res.insert(file_id, range); 142 res.insert(file_id, range);