Skip to content

Commit 727e41c

Browse files
committed
Auto merge of #142675 - tmiasko:preserve-cache, r=<try>
Preserve caches in a call to shrink_to_fit A small follow up to #142542.
2 parents 6f935a0 + 8e266d9 commit 727e41c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

compiler/rustc_mir_transform/src/simplify.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ pub(super) fn simplify_cfg<'tcx>(tcx: TyCtxt<'tcx>, body: &mut Body<'tcx>) {
8282
remove_dead_blocks(body);
8383

8484
// FIXME: Should probably be moved into some kind of pass manager
85-
body.basic_blocks_mut().raw.shrink_to_fit();
85+
body.basic_blocks.as_mut_preserves_cfg().shrink_to_fit();
8686
}
8787

8888
impl<'tcx> crate::MirPass<'tcx> for SimplifyCfg {

0 commit comments

Comments
 (0)