mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-28 01:34:21 +00:00
Change maybe_body_owned_by to take local def id
Signed-off-by: Miguel Guarniz <mi9uel9@gmail.com>
This commit is contained in:
parent
61c6d16ade
commit
ca0996e3a0
@ -138,7 +138,7 @@ impl<'tcx> LateLintPass<'tcx> for Author {
|
||||
|
||||
fn check_item(cx: &LateContext<'_>, hir_id: HirId) {
|
||||
let hir = cx.tcx.hir();
|
||||
if let Some(body_id) = hir.maybe_body_owned_by(hir_id) {
|
||||
if let Some(body_id) = hir.maybe_body_owned_by(hir.local_def_id(hir_id)) {
|
||||
check_node(cx, hir_id, |v| {
|
||||
v.expr(&v.bind("expr", &hir.body(body_id).value));
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user