@@ -418,11 +418,11 @@ fn mir_promoted(
418418 } ;
419419
420420 // the `has_ffi_unwind_calls` query uses the raw mir, so make sure it is run.
421- tcx. ensure_with_value ( ) . has_ffi_unwind_calls ( def) ;
421+ tcx. ensure_done ( ) . has_ffi_unwind_calls ( def) ;
422422
423423 // the `by_move_body` query uses the raw mir, so make sure it is run.
424424 if tcx. needs_coroutine_by_move_body_def_id ( def. to_def_id ( ) ) {
425- tcx. ensure_with_value ( ) . coroutine_by_move_body_def_id ( def) ;
425+ tcx. ensure_done ( ) . coroutine_by_move_body_def_id ( def) ;
426426 }
427427
428428 let mut body = tcx. mir_built ( def) . steal ( ) ;
@@ -485,7 +485,7 @@ fn inner_mir_for_ctfe(tcx: TyCtxt<'_>, def: LocalDefId) -> Body<'_> {
485485/// end up missing the source MIR due to stealing happening.
486486fn mir_drops_elaborated_and_const_checked ( tcx : TyCtxt < ' _ > , def : LocalDefId ) -> & Steal < Body < ' _ > > {
487487 if tcx. is_coroutine ( def. to_def_id ( ) ) {
488- tcx. ensure_with_value ( ) . mir_coroutine_witnesses ( def) ;
488+ tcx. ensure_done ( ) . mir_coroutine_witnesses ( def) ;
489489 }
490490
491491 // We only need to borrowck non-synthetic MIR.
@@ -498,7 +498,7 @@ fn mir_drops_elaborated_and_const_checked(tcx: TyCtxt<'_>, def: LocalDefId) -> &
498498 if pm:: should_run_pass ( tcx, & inline:: Inline , pm:: Optimizations :: Allowed )
499499 || inline:: ForceInline :: should_run_pass_for_callee ( tcx, def. to_def_id ( ) )
500500 {
501- tcx. ensure_with_value ( ) . mir_inliner_callees ( ty:: InstanceKind :: Item ( def. to_def_id ( ) ) ) ;
501+ tcx. ensure_done ( ) . mir_inliner_callees ( ty:: InstanceKind :: Item ( def. to_def_id ( ) ) ) ;
502502 }
503503 }
504504
@@ -729,7 +729,7 @@ fn inner_optimized_mir(tcx: TyCtxt<'_>, did: LocalDefId) -> Body<'_> {
729729 // Run the `mir_for_ctfe` query, which depends on `mir_drops_elaborated_and_const_checked`
730730 // which we are going to steal below. Thus we need to run `mir_for_ctfe` first, so it
731731 // computes and caches its result.
732- Some ( hir:: ConstContext :: ConstFn ) => tcx. ensure_with_value ( ) . mir_for_ctfe ( did) ,
732+ Some ( hir:: ConstContext :: ConstFn ) => tcx. ensure_done ( ) . mir_for_ctfe ( did) ,
733733 None => { }
734734 Some ( other) => panic ! ( "do not use `optimized_mir` for constants: {other:?}" ) ,
735735 }
@@ -768,7 +768,7 @@ fn promoted_mir(tcx: TyCtxt<'_>, def: LocalDefId) -> &IndexVec<Promoted, Body<'_
768768 }
769769
770770 if !tcx. is_synthetic_mir ( def) {
771- tcx. ensure_with_value ( ) . mir_borrowck ( def) ;
771+ tcx. ensure_done ( ) . mir_borrowck ( def) ;
772772 }
773773 let mut promoted = tcx. mir_promoted ( def) . 1 . steal ( ) ;
774774
0 commit comments