mirror of
https://github.com/rust-lang/rust.git
synced 2024-10-31 22:41:50 +00:00
4668123945
To reproduce the changes in this commit locally: - Run `./x test tidy` and remove all the output files not associated with a test file anymore, as reported by tidy. - Run `./x test tests/mir-opt --bless` to generate the new outputs.
28 lines
1.6 KiB
Diff
28 lines
1.6 KiB
Diff
- // MIR for `opt` before RemoveUnneededDrops
|
|
+ // MIR for `opt` after RemoveUnneededDrops
|
|
|
|
fn opt(_1: bool) -> () {
|
|
debug x => _1; // in scope 0 at $DIR/remove_unneeded_drops.rs:+0:8: +0:9
|
|
let mut _0: (); // return place in scope 0 at $DIR/remove_unneeded_drops.rs:+0:17: +0:17
|
|
let _2: (); // in scope 0 at $DIR/remove_unneeded_drops.rs:+1:5: +1:12
|
|
let mut _3: bool; // in scope 0 at $DIR/remove_unneeded_drops.rs:+1:10: +1:11
|
|
scope 1 (inlined std::mem::drop::<bool>) { // at $DIR/remove_unneeded_drops.rs:4:5: 4:12
|
|
debug _x => _3; // in scope 1 at $SRC_DIR/core/src/mem/mod.rs:LL:COL
|
|
}
|
|
|
|
bb0: {
|
|
- nop; // scope 0 at $DIR/remove_unneeded_drops.rs:+1:5: +1:12
|
|
StorageLive(_3); // scope 0 at $DIR/remove_unneeded_drops.rs:+1:10: +1:11
|
|
_3 = _1; // scope 0 at $DIR/remove_unneeded_drops.rs:+1:10: +1:11
|
|
- drop(_3) -> [return: bb1, unwind unreachable]; // scope 1 at $SRC_DIR/core/src/mem/mod.rs:LL:COL
|
|
- }
|
|
-
|
|
- bb1: {
|
|
StorageDead(_3); // scope 0 at $DIR/remove_unneeded_drops.rs:+1:11: +1:12
|
|
- nop; // scope 0 at $DIR/remove_unneeded_drops.rs:+1:12: +1:13
|
|
- nop; // scope 0 at $DIR/remove_unneeded_drops.rs:+0:17: +2:2
|
|
return; // scope 0 at $DIR/remove_unneeded_drops.rs:+2:2: +2:2
|
|
}
|
|
}
|
|
|