diff options
Diffstat (limited to 'components/script_plugins/utils.rs')
-rw-r--r-- | components/script_plugins/utils.rs | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/components/script_plugins/utils.rs b/components/script_plugins/utils.rs index 686b104daf6..6815b7bb0a6 100644 --- a/components/script_plugins/utils.rs +++ b/components/script_plugins/utils.rs @@ -30,12 +30,8 @@ pub fn match_def_path(cx: &LateContext, def_id: DefId, path: &[Symbol]) -> bool } pub fn in_derive_expn(span: Span) -> bool { - if let Some(i) = span.ctxt().outer_expn().expn_info() { - if let ExpnKind::Macro(MacroKind::Attr, n) = i.kind { - n.as_str().contains("derive") - } else { - false - } + if let ExpnKind::Macro(MacroKind::Attr, n) = span.ctxt().outer_expn_data().kind { + n.as_str().contains("derive") } else { false } |