From 68f66e0f446a2bd2385cfd236856f2a73bd58a3d Mon Sep 17 00:00:00 2001 From: Aleksey Kladov Date: Tue, 27 Nov 2018 16:32:36 +0300 Subject: add db to resolve_path --- crates/ra_analysis/src/completion/reference_completion.rs | 2 +- crates/ra_analysis/src/descriptors/module/mod.rs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/crates/ra_analysis/src/completion/reference_completion.rs b/crates/ra_analysis/src/completion/reference_completion.rs index 41df881b3..924d2440f 100644 --- a/crates/ra_analysis/src/completion/reference_completion.rs +++ b/crates/ra_analysis/src/completion/reference_completion.rs @@ -157,7 +157,7 @@ fn complete_path( return Ok(()); } path.segments.pop(); - let target_module = match module.resolve_path(path)? { + let target_module = match module.resolve_path(db, path)? { None => return Ok(()), Some(it) => it, }; diff --git a/crates/ra_analysis/src/descriptors/module/mod.rs b/crates/ra_analysis/src/descriptors/module/mod.rs index f5238e239..6890d8b09 100644 --- a/crates/ra_analysis/src/descriptors/module/mod.rs +++ b/crates/ra_analysis/src/descriptors/module/mod.rs @@ -133,7 +133,7 @@ impl ModuleDescriptor { Ok(res) } - pub(crate) fn resolve_path(&self, path: Path) -> Cancelable> { + pub(crate) fn resolve_path(&self, db: &impl DescriptorDatabase, path: Path) -> Cancelable> { let res = match self.do_resolve_path(path) { None => return Ok(None), Some(it) => it, -- cgit v1.2.3