aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_db/src/input.rs
diff options
context:
space:
mode:
Diffstat (limited to 'crates/ra_db/src/input.rs')
-rw-r--r--crates/ra_db/src/input.rs3
1 files changed, 3 insertions, 0 deletions
diff --git a/crates/ra_db/src/input.rs b/crates/ra_db/src/input.rs
index f445e03bc..7c3dd9296 100644
--- a/crates/ra_db/src/input.rs
+++ b/crates/ra_db/src/input.rs
@@ -101,6 +101,9 @@ impl CrateGraph {
101 } 101 }
102 self.arena.get_mut(&from).unwrap().add_dep(name, to) 102 self.arena.get_mut(&from).unwrap().add_dep(name, to)
103 } 103 }
104 pub fn is_empty(&self) -> bool {
105 self.arena.is_empty()
106 }
104 pub fn crate_root(&self, crate_id: CrateId) -> FileId { 107 pub fn crate_root(&self, crate_id: CrateId) -> FileId {
105 self.arena[&crate_id].file_id 108 self.arena[&crate_id].file_id
106 } 109 }