diff options
author | Jonas Schievink <[email protected]> | 2020-12-15 19:33:05 +0000 |
---|---|---|
committer | Jonas Schievink <[email protected]> | 2020-12-15 19:33:05 +0000 |
commit | b238ddd21adf9910769522a21e31c2e14f664396 (patch) | |
tree | 219749056bcef5cd35cfc94826108c4f955b1c8b /crates/hir/src/semantics | |
parent | c31c3246a8c87a3639623c30b692a57e728bb046 (diff) |
Make macro def krate mandatory
Refactors builtin derive support to go through proper name resolution
Diffstat (limited to 'crates/hir/src/semantics')
-rw-r--r-- | crates/hir/src/semantics/source_to_def.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/crates/hir/src/semantics/source_to_def.rs b/crates/hir/src/semantics/source_to_def.rs index d499ae340..3efca5baa 100644 --- a/crates/hir/src/semantics/source_to_def.rs +++ b/crates/hir/src/semantics/source_to_def.rs | |||
@@ -158,7 +158,7 @@ impl SourceToDefCtx<'_, '_> { | |||
158 | let krate = self.file_to_def(file_id)?.krate; | 158 | let krate = self.file_to_def(file_id)?.krate; |
159 | let file_ast_id = self.db.ast_id_map(src.file_id).ast_id(&src.value); | 159 | let file_ast_id = self.db.ast_id_map(src.file_id).ast_id(&src.value); |
160 | let ast_id = Some(AstId::new(src.file_id, file_ast_id.upcast())); | 160 | let ast_id = Some(AstId::new(src.file_id, file_ast_id.upcast())); |
161 | Some(MacroDefId { krate: Some(krate), ast_id, kind, local_inner: false }) | 161 | Some(MacroDefId { krate, ast_id, kind, local_inner: false }) |
162 | } | 162 | } |
163 | 163 | ||
164 | pub(super) fn find_container(&mut self, src: InFile<&SyntaxNode>) -> Option<ChildContainer> { | 164 | pub(super) fn find_container(&mut self, src: InFile<&SyntaxNode>) -> Option<ChildContainer> { |