diff options
author | Aleksey Kladov <[email protected]> | 2020-06-05 15:45:20 +0100 |
---|---|---|
committer | Aleksey Kladov <[email protected]> | 2020-06-05 16:22:56 +0100 |
commit | bbb40d746368eb6a38498649a723c7ead0ef8136 (patch) | |
tree | 6496e07d1558ef7b1f8c0cb51648fd44755c8f8e /crates/ra_hir_def/src | |
parent | 9c52f527a1cef7d39c2b1c55b49dc5459d392a4d (diff) |
Minimize FileLoader interface
Diffstat (limited to 'crates/ra_hir_def/src')
-rw-r--r-- | crates/ra_hir_def/src/test_db.rs | 12 |
1 files changed, 1 insertions, 11 deletions
diff --git a/crates/ra_hir_def/src/test_db.rs b/crates/ra_hir_def/src/test_db.rs index e7a5182f0..bcfa66ac9 100644 --- a/crates/ra_hir_def/src/test_db.rs +++ b/crates/ra_hir_def/src/test_db.rs | |||
@@ -6,9 +6,7 @@ use std::{ | |||
6 | }; | 6 | }; |
7 | 7 | ||
8 | use hir_expand::db::AstDatabase; | 8 | use hir_expand::db::AstDatabase; |
9 | use ra_db::{ | 9 | use ra_db::{salsa, CrateId, FileId, FileLoader, FileLoaderDelegate, Upcast}; |
10 | salsa, CrateId, ExternSourceId, FileId, FileLoader, FileLoaderDelegate, RelativePath, Upcast, | ||
11 | }; | ||
12 | 10 | ||
13 | use crate::db::DefDatabase; | 11 | use crate::db::DefDatabase; |
14 | 12 | ||
@@ -64,14 +62,6 @@ impl FileLoader for TestDB { | |||
64 | fn relevant_crates(&self, file_id: FileId) -> Arc<Vec<CrateId>> { | 62 | fn relevant_crates(&self, file_id: FileId) -> Arc<Vec<CrateId>> { |
65 | FileLoaderDelegate(self).relevant_crates(file_id) | 63 | FileLoaderDelegate(self).relevant_crates(file_id) |
66 | } | 64 | } |
67 | |||
68 | fn resolve_extern_path( | ||
69 | &self, | ||
70 | extern_id: ExternSourceId, | ||
71 | relative_path: &RelativePath, | ||
72 | ) -> Option<FileId> { | ||
73 | FileLoaderDelegate(self).resolve_extern_path(extern_id, relative_path) | ||
74 | } | ||
75 | } | 65 | } |
76 | 66 | ||
77 | impl TestDB { | 67 | impl TestDB { |