aboutsummaryrefslogtreecommitdiff
path: root/crates/hir_expand/src/db.rs
diff options
context:
space:
mode:
authorJonas Schievink <[email protected]>2021-05-10 21:54:17 +0100
committerJonas Schievink <[email protected]>2021-05-10 21:54:17 +0100
commit8ea9d939d2c44feb71e2d1c8ec390a9471b75e57 (patch)
tree3c7eff71e1778213524d57f4aee14bfaf9e35a68 /crates/hir_expand/src/db.rs
parentda08198bc94b9c51338cd94aeadc73324b373011 (diff)
Rewrite `#[derive]` removal to be based on AST
Diffstat (limited to 'crates/hir_expand/src/db.rs')
-rw-r--r--crates/hir_expand/src/db.rs7
1 files changed, 4 insertions, 3 deletions
diff --git a/crates/hir_expand/src/db.rs b/crates/hir_expand/src/db.rs
index 6647e57e7..9fa419fcf 100644
--- a/crates/hir_expand/src/db.rs
+++ b/crates/hir_expand/src/db.rs
@@ -12,9 +12,9 @@ use syntax::{
12}; 12};
13 13
14use crate::{ 14use crate::{
15 ast_id_map::AstIdMap, hygiene::HygieneFrame, BuiltinDeriveExpander, BuiltinFnLikeExpander, 15 ast_id_map::AstIdMap, hygiene::HygieneFrame, input::process_macro_input, BuiltinDeriveExpander,
16 EagerCallLoc, EagerMacroId, HirFileId, HirFileIdRepr, LazyMacroId, MacroCallId, MacroCallLoc, 16 BuiltinFnLikeExpander, EagerCallLoc, EagerMacroId, HirFileId, HirFileIdRepr, LazyMacroId,
17 MacroDefId, MacroDefKind, MacroFile, ProcMacroExpander, 17 MacroCallId, MacroCallLoc, MacroDefId, MacroDefKind, MacroFile, ProcMacroExpander,
18}; 18};
19 19
20/// Total limit on the number of tokens produced by any macro invocation. 20/// Total limit on the number of tokens produced by any macro invocation.
@@ -281,6 +281,7 @@ fn macro_arg_text(db: &dyn AstDatabase, id: MacroCallId) -> Option<GreenNode> {
281 }; 281 };
282 let loc = db.lookup_intern_macro(id); 282 let loc = db.lookup_intern_macro(id);
283 let arg = loc.kind.arg(db)?; 283 let arg = loc.kind.arg(db)?;
284 let arg = process_macro_input(db, arg, id);
284 Some(arg.green().into()) 285 Some(arg.green().into())
285} 286}
286 287