Unnamed repository; edit this file 'description' to name the repository.
Diffstat (limited to 'crates/hir_expand/src/lib.rs')
-rw-r--r--crates/hir_expand/src/lib.rs8
1 files changed, 3 insertions, 5 deletions
diff --git a/crates/hir_expand/src/lib.rs b/crates/hir_expand/src/lib.rs
index f227c7a7dd..ee9a65b266 100644
--- a/crates/hir_expand/src/lib.rs
+++ b/crates/hir_expand/src/lib.rs
@@ -465,11 +465,9 @@ impl ExpansionInfo {
_ => match origin {
mbe::Origin::Call => (&self.macro_arg.1, self.arg.clone()),
mbe::Origin::Def => match (&*self.macro_def, &self.attr_input_or_mac_def) {
- (
- TokenExpander::MacroRules { def_site_token_map, .. }
- | TokenExpander::MacroDef { def_site_token_map, .. },
- Some(tt),
- ) => (def_site_token_map, tt.syntax().cloned()),
+ (TokenExpander::DeclarativeMacro { def_site_token_map, .. }, Some(tt)) => {
+ (def_site_token_map, tt.syntax().cloned())
+ }
_ => panic!("`Origin::Def` used with non-`macro_rules!` macro"),
},
},