aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_db/src
diff options
context:
space:
mode:
Diffstat (limited to 'crates/ra_db/src')
-rw-r--r--crates/ra_db/src/lib.rs9
1 files changed, 2 insertions, 7 deletions
diff --git a/crates/ra_db/src/lib.rs b/crates/ra_db/src/lib.rs
index fd4280de2..07e1b8aba 100644
--- a/crates/ra_db/src/lib.rs
+++ b/crates/ra_db/src/lib.rs
@@ -89,8 +89,7 @@ pub const DEFAULT_LRU_CAP: usize = 128;
89pub trait FileLoader { 89pub trait FileLoader {
90 /// Text of the file. 90 /// Text of the file.
91 fn file_text(&self, file_id: FileId) -> Arc<String>; 91 fn file_text(&self, file_id: FileId) -> Arc<String>;
92 fn resolve_relative_path(&self, anchor: FileId, relative_path: &RelativePath) 92 fn resolve_path(&self, anchor: FileId, relative_path: &RelativePath) -> Option<FileId>;
93 -> Option<FileId>;
94 fn relevant_crates(&self, file_id: FileId) -> Arc<Vec<CrateId>>; 93 fn relevant_crates(&self, file_id: FileId) -> Arc<Vec<CrateId>>;
95 94
96 fn resolve_extern_path( 95 fn resolve_extern_path(
@@ -155,11 +154,7 @@ impl<T: SourceDatabaseExt> FileLoader for FileLoaderDelegate<&'_ T> {
155 fn file_text(&self, file_id: FileId) -> Arc<String> { 154 fn file_text(&self, file_id: FileId) -> Arc<String> {
156 SourceDatabaseExt::file_text(self.0, file_id) 155 SourceDatabaseExt::file_text(self.0, file_id)
157 } 156 }
158 fn resolve_relative_path( 157 fn resolve_path(&self, anchor: FileId, relative_path: &RelativePath) -> Option<FileId> {
159 &self,
160 anchor: FileId,
161 relative_path: &RelativePath,
162 ) -> Option<FileId> {
163 let path = { 158 let path = {
164 let mut path = self.0.file_relative_path(anchor); 159 let mut path = self.0.file_relative_path(anchor);
165 assert!(path.pop()); 160 assert!(path.pop());