aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_ide_db/src/search.rs
diff options
context:
space:
mode:
Diffstat (limited to 'crates/ra_ide_db/src/search.rs')
-rw-r--r--crates/ra_ide_db/src/search.rs5
1 files changed, 2 insertions, 3 deletions
diff --git a/crates/ra_ide_db/src/search.rs b/crates/ra_ide_db/src/search.rs
index 0b862b449..d90b830d0 100644
--- a/crates/ra_ide_db/src/search.rs
+++ b/crates/ra_ide_db/src/search.rs
@@ -9,7 +9,6 @@ use std::{convert::TryInto, mem};
9use hir::{DefWithBody, HasSource, Module, ModuleSource, Semantics, Visibility}; 9use hir::{DefWithBody, HasSource, Module, ModuleSource, Semantics, Visibility};
10use once_cell::unsync::Lazy; 10use once_cell::unsync::Lazy;
11use ra_db::{FileId, FileRange, SourceDatabaseExt}; 11use ra_db::{FileId, FileRange, SourceDatabaseExt};
12use ra_prof::profile;
13use ra_syntax::{ast, match_ast, AstNode, TextRange, TextSize}; 12use ra_syntax::{ast, match_ast, AstNode, TextRange, TextSize};
14use rustc_hash::FxHashMap; 13use rustc_hash::FxHashMap;
15 14
@@ -107,7 +106,7 @@ impl IntoIterator for SearchScope {
107 106
108impl Definition { 107impl Definition {
109 fn search_scope(&self, db: &RootDatabase) -> SearchScope { 108 fn search_scope(&self, db: &RootDatabase) -> SearchScope {
110 let _p = profile("search_scope"); 109 let _p = profile::span("search_scope");
111 let module = match self.module(db) { 110 let module = match self.module(db) {
112 Some(it) => it, 111 Some(it) => it,
113 None => return SearchScope::empty(), 112 None => return SearchScope::empty(),
@@ -187,7 +186,7 @@ impl Definition {
187 sema: &Semantics<RootDatabase>, 186 sema: &Semantics<RootDatabase>,
188 search_scope: Option<SearchScope>, 187 search_scope: Option<SearchScope>,
189 ) -> Vec<Reference> { 188 ) -> Vec<Reference> {
190 let _p = profile("Definition::find_usages"); 189 let _p = profile::span("Definition::find_usages");
191 190
192 let search_scope = { 191 let search_scope = {
193 let base = self.search_scope(sema.db); 192 let base = self.search_scope(sema.db);