diff options
Diffstat (limited to 'crates/ra_hir/src/db.rs')
-rw-r--r-- | crates/ra_hir/src/db.rs | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/crates/ra_hir/src/db.rs b/crates/ra_hir/src/db.rs index f0bff3c02..d94f75857 100644 --- a/crates/ra_hir/src/db.rs +++ b/crates/ra_hir/src/db.rs | |||
@@ -14,7 +14,7 @@ use crate::{ | |||
14 | function::FnId, | 14 | function::FnId, |
15 | module::{ModuleId, ModuleTree, ModuleSource, | 15 | module::{ModuleId, ModuleTree, ModuleSource, |
16 | nameres::{ItemMap, InputModuleItems}}, | 16 | nameres::{ItemMap, InputModuleItems}}, |
17 | ty::InferenceResult, | 17 | ty::{InferenceResult, Ty}, |
18 | }; | 18 | }; |
19 | 19 | ||
20 | salsa::query_group! { | 20 | salsa::query_group! { |
@@ -31,11 +31,16 @@ pub trait HirDatabase: SyntaxDatabase | |||
31 | use fn query_definitions::fn_syntax; | 31 | use fn query_definitions::fn_syntax; |
32 | } | 32 | } |
33 | 33 | ||
34 | fn infer(fn_id: FnId) -> Arc<InferenceResult> { | 34 | fn infer(fn_id: FnId) -> Cancelable<Arc<InferenceResult>> { |
35 | type InferQuery; | 35 | type InferQuery; |
36 | use fn query_definitions::infer; | 36 | use fn query_definitions::infer; |
37 | } | 37 | } |
38 | 38 | ||
39 | fn type_for_def(def_id: DefId) -> Cancelable<Ty> { | ||
40 | type TypeForDefQuery; | ||
41 | use fn query_definitions::type_for_def; | ||
42 | } | ||
43 | |||
39 | fn file_items(file_id: FileId) -> Arc<SourceFileItems> { | 44 | fn file_items(file_id: FileId) -> Arc<SourceFileItems> { |
40 | type SourceFileItemsQuery; | 45 | type SourceFileItemsQuery; |
41 | use fn query_definitions::file_items; | 46 | use fn query_definitions::file_items; |