add db to resolve_path

This commit is contained in:
Aleksey Kladov 2018-11-27 16:32:36 +03:00
parent 5b0e347f89
commit 68f66e0f44
2 changed files with 2 additions and 2 deletions

View file

@ -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,
};

View file

@ -133,7 +133,7 @@ impl ModuleDescriptor {
Ok(res)
}
pub(crate) fn resolve_path(&self, path: Path) -> Cancelable<Option<ModuleDescriptor>> {
pub(crate) fn resolve_path(&self, db: &impl DescriptorDatabase, path: Path) -> Cancelable<Option<ModuleDescriptor>> {
let res = match self.do_resolve_path(path) {
None => return Ok(None),
Some(it) => it,