diff options
author | Vincent Rouillé <[email protected]> | 2019-12-04 22:05:01 +0000 |
---|---|---|
committer | Vincent Rouillé <[email protected]> | 2019-12-04 22:05:01 +0000 |
commit | b437dca4bd100c0a7a498d5960d566a0ccd92432 (patch) | |
tree | f714271189e0267324265830e4c3dc513b81cb11 /crates/ra_ide | |
parent | 1fe0b8c03fa613262afd2d612c55cc3a11249c7e (diff) |
Run rustfmt with respect to Cargo.toml edition
Diffstat (limited to 'crates/ra_ide')
-rw-r--r-- | crates/ra_ide/src/lib.rs | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/crates/ra_ide/src/lib.rs b/crates/ra_ide/src/lib.rs index d1bff4a76..779a81b2c 100644 --- a/crates/ra_ide/src/lib.rs +++ b/crates/ra_ide/src/lib.rs | |||
@@ -422,6 +422,11 @@ impl Analysis { | |||
422 | self.with_db(|db| parent_module::crate_for(db, file_id)) | 422 | self.with_db(|db| parent_module::crate_for(db, file_id)) |
423 | } | 423 | } |
424 | 424 | ||
425 | /// Returns the edition of the given crate. | ||
426 | pub fn crate_edition(&self, crate_id: CrateId) -> Cancelable<Edition> { | ||
427 | self.with_db(|db| db.crate_graph().edition(crate_id)) | ||
428 | } | ||
429 | |||
425 | /// Returns the root file of the given crate. | 430 | /// Returns the root file of the given crate. |
426 | pub fn crate_root(&self, crate_id: CrateId) -> Cancelable<FileId> { | 431 | pub fn crate_root(&self, crate_id: CrateId) -> Cancelable<FileId> { |
427 | self.with_db(|db| db.crate_graph().crate_root(crate_id)) | 432 | self.with_db(|db| db.crate_graph().crate_root(crate_id)) |