diff options
author | bors[bot] <bors[bot]@users.noreply.github.com> | 2019-02-05 07:53:08 +0000 |
---|---|---|
committer | bors[bot] <bors[bot]@users.noreply.github.com> | 2019-02-05 07:53:08 +0000 |
commit | 4d4c46aff8f9a7ce8c2f91fbe6c7c363f5d3e08c (patch) | |
tree | 90473c4a67ac70ee40fde54a25b11d7768c41593 /crates/ra_hir/src/code_model_api.rs | |
parent | 94d5d0d7e893a50bdd22ce4366ca15f083218d22 (diff) | |
parent | de4c5e381fb1adc25143dcd67af6c87f6d9789ae (diff) |
Merge #742
742: Extern crate r=matklad a=flodiebold
This implements `extern crate` declarations by lowering them to (absolute) imports, and adds support for absolute paths. It also extracts the extern prelude from the per-module item map, and handles the special case of extern crates in the crate root adding to the extern prelude.
This means we finally resolve `Arc`, so it fixes #523 :smile:
Co-authored-by: Florian Diebold <[email protected]>
Diffstat (limited to 'crates/ra_hir/src/code_model_api.rs')
-rw-r--r-- | crates/ra_hir/src/code_model_api.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/crates/ra_hir/src/code_model_api.rs b/crates/ra_hir/src/code_model_api.rs index 92ab0f692..a58bf8f87 100644 --- a/crates/ra_hir/src/code_model_api.rs +++ b/crates/ra_hir/src/code_model_api.rs | |||
@@ -134,7 +134,7 @@ impl Module { | |||
134 | } | 134 | } |
135 | 135 | ||
136 | /// Returns the crate this module is part of. | 136 | /// Returns the crate this module is part of. |
137 | pub fn krate(&self, _db: &impl HirDatabase) -> Option<Crate> { | 137 | pub fn krate(&self, _db: &impl PersistentHirDatabase) -> Option<Crate> { |
138 | Some(self.krate) | 138 | Some(self.krate) |
139 | } | 139 | } |
140 | 140 | ||