rust/tests/mir-opt/building/issue_49232.main.built.after.mir
2024-02-12 17:37:05 +01:00

85 lines
1.3 KiB
Rust

// MIR for `main` after built
fn main() -> () {
let mut _0: ();
let mut _1: ();
let _2: i32;
let mut _3: bool;
let mut _4: !;
let _5: ();
let mut _6: &i32;
scope 1 {
debug beacon => _2;
}
bb0: {
goto -> bb1;
}
bb1: {
falseUnwind -> [real: bb2, unwind: bb12];
}
bb2: {
StorageLive(_2);
StorageLive(_3);
_3 = const true;
PlaceMention(_3);
switchInt(_3) -> [0: bb4, otherwise: bb5];
}
bb3: {
FakeRead(ForMatchedPlace(None), _3);
unreachable;
}
bb4: {
falseEdge -> [real: bb6, imaginary: bb5];
}
bb5: {
_0 = const ();
goto -> bb11;
}
bb6: {
_2 = const 4_i32;
goto -> bb9;
}
bb7: {
unreachable;
}
bb8: {
goto -> bb9;
}
bb9: {
FakeRead(ForLet(None), _2);
StorageDead(_3);
StorageLive(_5);
StorageLive(_6);
_6 = &_2;
_5 = std::mem::drop::<&i32>(move _6) -> [return: bb10, unwind: bb12];
}
bb10: {
StorageDead(_6);
StorageDead(_5);
_1 = const ();
StorageDead(_2);
goto -> bb1;
}
bb11: {
StorageDead(_3);
StorageDead(_2);
return;
}
bb12 (cleanup): {
resume;
}
}