From 18f6a995d0fc1f45099f3cc810a5d55d5401b41b Mon Sep 17 00:00:00 2001 From: Florian Diebold Date: Thu, 5 Dec 2019 15:10:33 +0100 Subject: Add expansion infrastructure for derive macros --- crates/ra_hir/src/source_binder.rs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'crates/ra_hir/src/source_binder.rs') diff --git a/crates/ra_hir/src/source_binder.rs b/crates/ra_hir/src/source_binder.rs index db0451059..42c392513 100644 --- a/crates/ra_hir/src/source_binder.rs +++ b/crates/ra_hir/src/source_binder.rs @@ -20,7 +20,8 @@ use hir_def::{ AssocItemId, DefWithBodyId, }; use hir_expand::{ - hygiene::Hygiene, name::AsName, AstId, HirFileId, InFile, MacroCallId, MacroFileKind, + hygiene::Hygiene, name::AsName, AstId, HirFileId, InFile, MacroCallId, MacroCallKind, + MacroFileKind, }; use ra_syntax::{ ast::{self, AstNode}, @@ -456,7 +457,7 @@ impl SourceAnalyzer { db.ast_id_map(macro_call.file_id).ast_id(macro_call.value), ); Some(Expansion { - macro_call_id: def.as_call_id(db, ast_id), + macro_call_id: def.as_call_id(db, MacroCallKind::FnLike(ast_id)), macro_file_kind: to_macro_file_kind(macro_call.value), }) } -- cgit v1.2.3