From 8cd23a4fb8c6a1012ba3e40dd3329a5abaed06b7 Mon Sep 17 00:00:00 2001 From: uHOOCCOOHu Date: Fri, 27 Sep 2019 00:16:55 +0800 Subject: Store crate info in `MacroDefId` --- crates/ra_hir/src/code_model/src.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'crates/ra_hir/src/code_model/src.rs') diff --git a/crates/ra_hir/src/code_model/src.rs b/crates/ra_hir/src/code_model/src.rs index c0cb27b47..dc964e156 100644 --- a/crates/ra_hir/src/code_model/src.rs +++ b/crates/ra_hir/src/code_model/src.rs @@ -119,7 +119,7 @@ impl HasSource for TypeAlias { impl HasSource for MacroDef { type Ast = ast::MacroCall; fn source(self, db: &(impl DefDatabase + AstDatabase)) -> Source { - Source { file_id: self.id.0.file_id(), ast: self.id.0.to_node(db) } + Source { file_id: self.id.ast_id.file_id(), ast: self.id.ast_id.to_node(db) } } } -- cgit v1.2.3