We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 26833b6 commit 4d04916Copy full SHA for 4d04916
1 file changed
compiler/rustc_mir_transform/src/remove_dead_drops.rs
@@ -14,6 +14,10 @@ impl<'tcx> crate::MirPass<'tcx> for RemoveDeadDrops {
14
}
15
16
fn run_pass(&self, tcx: TyCtxt<'tcx>, body: &mut Body<'tcx>) {
17
+ if body.coroutine.is_none() {
18
+ return;
19
+ }
20
+
21
let move_data = MoveData::gather_moves(body, tcx, |_| true);
22
23
let mut maybe_init_cursor = MaybeInitializedPlaces::new(tcx, body, &move_data)
0 commit comments