diff options
Diffstat (limited to 'crates/ra_hir_def/src/lang_item.rs')
-rw-r--r-- | crates/ra_hir_def/src/lang_item.rs | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/crates/ra_hir_def/src/lang_item.rs b/crates/ra_hir_def/src/lang_item.rs index 3516784b8..3631499bf 100644 --- a/crates/ra_hir_def/src/lang_item.rs +++ b/crates/ra_hir_def/src/lang_item.rs | |||
@@ -4,7 +4,6 @@ | |||
4 | //! features, such as Fn family of traits. | 4 | //! features, such as Fn family of traits. |
5 | use std::sync::Arc; | 5 | use std::sync::Arc; |
6 | 6 | ||
7 | use ra_prof::profile; | ||
8 | use ra_syntax::SmolStr; | 7 | use ra_syntax::SmolStr; |
9 | use rustc_hash::FxHashMap; | 8 | use rustc_hash::FxHashMap; |
10 | 9 | ||
@@ -79,7 +78,7 @@ impl LangItems { | |||
79 | 78 | ||
80 | /// Salsa query. This will look for lang items in a specific crate. | 79 | /// Salsa query. This will look for lang items in a specific crate. |
81 | pub(crate) fn crate_lang_items_query(db: &dyn DefDatabase, krate: CrateId) -> Arc<LangItems> { | 80 | pub(crate) fn crate_lang_items_query(db: &dyn DefDatabase, krate: CrateId) -> Arc<LangItems> { |
82 | let _p = profile("crate_lang_items_query"); | 81 | let _p = profile::span("crate_lang_items_query"); |
83 | 82 | ||
84 | let mut lang_items = LangItems::default(); | 83 | let mut lang_items = LangItems::default(); |
85 | 84 | ||
@@ -98,7 +97,7 @@ impl LangItems { | |||
98 | db: &dyn DefDatabase, | 97 | db: &dyn DefDatabase, |
99 | module: ModuleId, | 98 | module: ModuleId, |
100 | ) -> Option<Arc<LangItems>> { | 99 | ) -> Option<Arc<LangItems>> { |
101 | let _p = profile("module_lang_items_query"); | 100 | let _p = profile::span("module_lang_items_query"); |
102 | let mut lang_items = LangItems::default(); | 101 | let mut lang_items = LangItems::default(); |
103 | lang_items.collect_lang_items(db, module); | 102 | lang_items.collect_lang_items(db, module); |
104 | if lang_items.items.is_empty() { | 103 | if lang_items.items.is_empty() { |
@@ -115,7 +114,7 @@ impl LangItems { | |||
115 | start_crate: CrateId, | 114 | start_crate: CrateId, |
116 | item: SmolStr, | 115 | item: SmolStr, |
117 | ) -> Option<LangItemTarget> { | 116 | ) -> Option<LangItemTarget> { |
118 | let _p = profile("lang_item_query"); | 117 | let _p = profile::span("lang_item_query"); |
119 | let lang_items = db.crate_lang_items(start_crate); | 118 | let lang_items = db.crate_lang_items(start_crate); |
120 | let start_crate_target = lang_items.items.get(&item); | 119 | let start_crate_target = lang_items.items.get(&item); |
121 | if let Some(target) = start_crate_target { | 120 | if let Some(target) = start_crate_target { |