]> git.lizzy.rs Git - rust.git/blobdiff - compiler/rustc_mir_transform/src/lib.rs
Replace FnLikeNode by FnKind.
[rust.git] / compiler / rustc_mir_transform / src / lib.rs
index 9b11c8f0b24c0836fb96b3d31f82236d26e10b85..269ad7f6bf4820c653ff92e75786b4fa83dde348 100644 (file)
@@ -428,8 +428,7 @@ fn mir_drops_elaborated_and_const_checked<'tcx>(
     }
 
     let hir_id = tcx.hir().local_def_id_to_hir_id(def.did);
-    use rustc_middle::hir::map::blocks::FnLikeNode;
-    let is_fn_like = FnLikeNode::from_node(tcx.hir().get(hir_id)).is_some();
+    let is_fn_like = tcx.hir().get(hir_id).fn_kind().is_some();
     if is_fn_like {
         let did = def.did.to_def_id();
         let def = ty::WithOptConstParam::unknown(did);