aboutsummaryrefslogtreecommitdiff
path: root/crates/hir_ty/src/test_db.rs
diff options
context:
space:
mode:
Diffstat (limited to 'crates/hir_ty/src/test_db.rs')
-rw-r--r--crates/hir_ty/src/test_db.rs8
1 files changed, 5 insertions, 3 deletions
diff --git a/crates/hir_ty/src/test_db.rs b/crates/hir_ty/src/test_db.rs
index 22254b765..646e16bbe 100644
--- a/crates/hir_ty/src/test_db.rs
+++ b/crates/hir_ty/src/test_db.rs
@@ -5,7 +5,9 @@ use std::{
5 sync::{Arc, Mutex}, 5 sync::{Arc, Mutex},
6}; 6};
7 7
8use base_db::{salsa, CrateId, FileId, FileLoader, FileLoaderDelegate, SourceDatabase, Upcast}; 8use base_db::{
9 salsa, AnchoredPath, CrateId, FileId, FileLoader, FileLoaderDelegate, SourceDatabase, Upcast,
10};
9use hir_def::{db::DefDatabase, ModuleId}; 11use hir_def::{db::DefDatabase, ModuleId};
10use hir_expand::db::AstDatabase; 12use hir_expand::db::AstDatabase;
11use rustc_hash::{FxHashMap, FxHashSet}; 13use rustc_hash::{FxHashMap, FxHashSet};
@@ -67,8 +69,8 @@ impl FileLoader for TestDB {
67 fn file_text(&self, file_id: FileId) -> Arc<String> { 69 fn file_text(&self, file_id: FileId) -> Arc<String> {
68 FileLoaderDelegate(self).file_text(file_id) 70 FileLoaderDelegate(self).file_text(file_id)
69 } 71 }
70 fn resolve_path(&self, anchor: FileId, path: &str) -> Option<FileId> { 72 fn resolve_path(&self, path: AnchoredPath) -> Option<FileId> {
71 FileLoaderDelegate(self).resolve_path(anchor, path) 73 FileLoaderDelegate(self).resolve_path(path)
72 } 74 }
73 fn relevant_crates(&self, file_id: FileId) -> Arc<FxHashSet<CrateId>> { 75 fn relevant_crates(&self, file_id: FileId) -> Arc<FxHashSet<CrateId>> {
74 FileLoaderDelegate(self).relevant_crates(file_id) 76 FileLoaderDelegate(self).relevant_crates(file_id)