Skip to content

Commit e5cba17

Browse files
committed
Use the HIR instead of mir_keys for determining whether something will have a MIR body.
1 parent 53e3c32 commit e5cba17

File tree

1 file changed

+1
-1
lines changed
  • compiler/rustc_mir_transform/src

1 file changed

+1
-1
lines changed

compiler/rustc_mir_transform/src/lib.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -211,7 +211,7 @@ fn remap_mir_for_const_eval_select<'tcx>(
211211
}
212212

213213
fn is_mir_available(tcx: TyCtxt<'_>, def_id: LocalDefId) -> bool {
214-
tcx.mir_keys(()).contains(&def_id)
214+
tcx.hir().maybe_body_owned_by(def_id).is_some()
215215
}
216216

217217
/// Finds the full set of `DefId`s within the current crate that have

0 commit comments

Comments
 (0)