diff options
author | Seivan Heidari <[email protected]> | 2019-11-18 01:27:53 +0000 |
---|---|---|
committer | Seivan Heidari <[email protected]> | 2019-11-18 01:27:53 +0000 |
commit | 166636ba77adcf5bf2c4ef935e9aa75e20f25e10 (patch) | |
tree | 168be1ca55c73b016e20586c08417c608450c92c /crates/ra_hir_def/src/nameres.rs | |
parent | cb26df950699586b314731fb70786e0db8eaa049 (diff) | |
parent | 28c2d74b2150102a8756a5357a5a965d7610bd15 (diff) |
Merge branch 'master' of https://github.com/rust-analyzer/rust-analyzer into feature/themes
Diffstat (limited to 'crates/ra_hir_def/src/nameres.rs')
-rw-r--r-- | crates/ra_hir_def/src/nameres.rs | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/crates/ra_hir_def/src/nameres.rs b/crates/ra_hir_def/src/nameres.rs index 21d5f62e0..e5b073a0f 100644 --- a/crates/ra_hir_def/src/nameres.rs +++ b/crates/ra_hir_def/src/nameres.rs | |||
@@ -73,7 +73,7 @@ use crate::{ | |||
73 | diagnostics::DefDiagnostic, path_resolution::ResolveMode, per_ns::PerNs, raw::ImportId, | 73 | diagnostics::DefDiagnostic, path_resolution::ResolveMode, per_ns::PerNs, raw::ImportId, |
74 | }, | 74 | }, |
75 | path::Path, | 75 | path::Path, |
76 | AstId, CrateModuleId, FunctionId, ModuleDefId, ModuleId, TraitId, | 76 | AstId, CrateModuleId, FunctionId, ImplId, ModuleDefId, ModuleId, TraitId, |
77 | }; | 77 | }; |
78 | 78 | ||
79 | /// Contains all top-level defs from a macro-expanded crate | 79 | /// Contains all top-level defs from a macro-expanded crate |
@@ -122,16 +122,17 @@ pub struct ModuleData { | |||
122 | /// | 122 | /// |
123 | /// Note that non-inline modules, by definition, live inside non-macro file. | 123 | /// Note that non-inline modules, by definition, live inside non-macro file. |
124 | pub definition: Option<FileId>, | 124 | pub definition: Option<FileId>, |
125 | pub impls: Vec<ImplId>, | ||
125 | } | 126 | } |
126 | 127 | ||
127 | #[derive(Default, Debug, PartialEq, Eq, Clone)] | 128 | #[derive(Default, Debug, PartialEq, Eq)] |
128 | pub(crate) struct Declarations { | 129 | pub(crate) struct Declarations { |
129 | fns: FxHashMap<FileAstId<ast::FnDef>, FunctionId>, | 130 | fns: FxHashMap<FileAstId<ast::FnDef>, FunctionId>, |
130 | } | 131 | } |
131 | 132 | ||
132 | #[derive(Debug, Default, PartialEq, Eq, Clone)] | 133 | #[derive(Debug, Default, PartialEq, Eq)] |
133 | pub struct ModuleScope { | 134 | pub struct ModuleScope { |
134 | pub items: FxHashMap<Name, Resolution>, | 135 | items: FxHashMap<Name, Resolution>, |
135 | /// Macros visable in current module in legacy textual scope | 136 | /// Macros visable in current module in legacy textual scope |
136 | /// | 137 | /// |
137 | /// For macros invoked by an unquatified identifier like `bar!()`, `legacy_macros` will be searched in first. | 138 | /// For macros invoked by an unquatified identifier like `bar!()`, `legacy_macros` will be searched in first. |