This commit is contained in:
Oliver Schneider
2017-08-15 11:10:49 +02:00
parent 3ab06c1f77
commit f3ae929b2d
27 changed files with 60 additions and 57 deletions

View File

@@ -361,7 +361,7 @@ impl<'a, 'tcx> LateLintPass<'a, 'tcx> for Pass {
binding != "_result" && // FIXME: #944
is_used(cx, expr) &&
// don't lint if the declaration is in a macro
non_macro_local(cx, &cx.tables.qpath_def(qpath, expr.id))
non_macro_local(cx, &cx.tables.qpath_def(qpath, expr.hir_id))
{
Some(binding)
} else {