aboutsummaryrefslogtreecommitdiff
path: root/crates/base_db/src
diff options
context:
space:
mode:
Diffstat (limited to 'crates/base_db/src')
-rw-r--r--crates/base_db/src/lib.rs7
1 files changed, 4 insertions, 3 deletions
diff --git a/crates/base_db/src/lib.rs b/crates/base_db/src/lib.rs
index 5571af495..a2cc1e099 100644
--- a/crates/base_db/src/lib.rs
+++ b/crates/base_db/src/lib.rs
@@ -18,7 +18,7 @@ pub use crate::{
18 }, 18 },
19}; 19};
20pub use salsa; 20pub use salsa;
21pub use vfs::{file_set::FileSet, FileId, VfsPath}; 21pub use vfs::{file_set::FileSet, AnchoredPath, AnchoredPathBuf, FileId, VfsPath};
22 22
23#[macro_export] 23#[macro_export]
24macro_rules! impl_intern_key { 24macro_rules! impl_intern_key {
@@ -156,10 +156,11 @@ impl<T: SourceDatabaseExt> FileLoader for FileLoaderDelegate<&'_ T> {
156 SourceDatabaseExt::file_text(self.0, file_id) 156 SourceDatabaseExt::file_text(self.0, file_id)
157 } 157 }
158 fn resolve_path(&self, anchor: FileId, path: &str) -> Option<FileId> { 158 fn resolve_path(&self, anchor: FileId, path: &str) -> Option<FileId> {
159 let path = AnchoredPath { anchor, path };
159 // FIXME: this *somehow* should be platform agnostic... 160 // FIXME: this *somehow* should be platform agnostic...
160 let source_root = self.0.file_source_root(anchor); 161 let source_root = self.0.file_source_root(path.anchor);
161 let source_root = self.0.source_root(source_root); 162 let source_root = self.0.source_root(source_root);
162 source_root.file_set.resolve_path(anchor, path) 163 source_root.file_set.resolve_path(path)
163 } 164 }
164 165
165 fn relevant_crates(&self, file_id: FileId) -> Arc<FxHashSet<CrateId>> { 166 fn relevant_crates(&self, file_id: FileId) -> Arc<FxHashSet<CrateId>> {