diff options
-rw-r--r-- | crates/ra_hir/src/code_model_api.rs | 4 | ||||
-rw-r--r-- | crates/ra_hir/src/module/nameres.rs | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/crates/ra_hir/src/code_model_api.rs b/crates/ra_hir/src/code_model_api.rs index 2f968d97c..f1e891722 100644 --- a/crates/ra_hir/src/code_model_api.rs +++ b/crates/ra_hir/src/code_model_api.rs | |||
@@ -21,8 +21,8 @@ impl Crate { | |||
21 | pub fn crate_id(&self) -> CrateId { | 21 | pub fn crate_id(&self) -> CrateId { |
22 | self.crate_id | 22 | self.crate_id |
23 | } | 23 | } |
24 | pub fn dependencies(&self, db: &impl HirDatabase) -> Vec<CrateDependency> { | 24 | pub fn dependencies(&self, db: &impl HirDatabase) -> Cancelable<Vec<CrateDependency>> { |
25 | self.dependencies_impl(db) | 25 | Ok(self.dependencies_impl(db)) |
26 | } | 26 | } |
27 | pub fn root_module(&self, db: &impl HirDatabase) -> Cancelable<Option<Module>> { | 27 | pub fn root_module(&self, db: &impl HirDatabase) -> Cancelable<Option<Module>> { |
28 | self.root_module_impl(db) | 28 | self.root_module_impl(db) |
diff --git a/crates/ra_hir/src/module/nameres.rs b/crates/ra_hir/src/module/nameres.rs index cd634e42f..059301b05 100644 --- a/crates/ra_hir/src/module/nameres.rs +++ b/crates/ra_hir/src/module/nameres.rs | |||
@@ -344,7 +344,7 @@ where | |||
344 | if let Some(crate_id) = crate_graph.crate_id_for_crate_root(file_id.as_original_file()) | 344 | if let Some(crate_id) = crate_graph.crate_id_for_crate_root(file_id.as_original_file()) |
345 | { | 345 | { |
346 | let krate = Crate::new(crate_id); | 346 | let krate = Crate::new(crate_id); |
347 | for dep in krate.dependencies(self.db) { | 347 | for dep in krate.dependencies(self.db)? { |
348 | if let Some(module) = dep.krate.root_module(self.db)? { | 348 | if let Some(module) = dep.krate.root_module(self.db)? { |
349 | let def_id = module.def_id; | 349 | let def_id = module.def_id; |
350 | self.add_module_item( | 350 | self.add_module_item( |