We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ca0996e commit 29a0f69Copy full SHA for 29a0f69
clippy_lints/src/utils/author.rs
@@ -138,7 +138,7 @@ impl<'tcx> LateLintPass<'tcx> for Author {
138
139
fn check_item(cx: &LateContext<'_>, hir_id: HirId) {
140
let hir = cx.tcx.hir();
141
- if let Some(body_id) = hir.maybe_body_owned_by(hir.local_def_id(hir_id)) {
+ if let Some(body_id) = hir.maybe_body_owned_by(hir_id.expect_owner()) {
142
check_node(cx, hir_id, |v| {
143
v.expr(&v.bind("expr", &hir.body(body_id).value));
144
});
0 commit comments