This commit is contained in:
Matthias Krüger
2018-12-08 01:56:03 +01:00
committed by Philipp Hansch
parent 26602ddff4
commit f13d23de41
46 changed files with 140 additions and 140 deletions

View File

@@ -612,7 +612,7 @@ fn in_attributes_expansion(expr: &Expr) -> bool {
/// Test whether `def` is a variable defined outside a macro.
fn non_macro_local(cx: &LateContext<'_, '_>, def: &def::Def) -> bool {
match *def {
def::Def::Local(id) | def::Def::Upvar(id, _, _) => !in_macro(cx.tcx.hir.span(id)),
def::Def::Local(id) | def::Def::Upvar(id, _, _) => !in_macro(cx.tcx.hir().span(id)),
_ => false,
}
}