2023-02-22 18:00:00 -06:00
|
|
|
- // MIR for `main` before ElaborateDrops
|
|
|
|
+ // MIR for `main` after ElaborateDrops
|
|
|
|
|
|
|
|
fn main() -> () {
|
|
|
|
let mut _0: (); // return place in scope 0 at $DIR/issue_41888.rs:+0:11: +0:11
|
|
|
|
let _1: E; // in scope 0 at $DIR/issue_41888.rs:+1:9: +1:10
|
|
|
|
let mut _2: bool; // in scope 0 at $DIR/issue_41888.rs:+2:8: +2:14
|
|
|
|
let mut _3: E; // in scope 0 at $DIR/issue_41888.rs:+3:13: +3:20
|
|
|
|
let mut _4: K; // in scope 0 at $DIR/issue_41888.rs:+3:18: +3:19
|
|
|
|
let mut _5: isize; // in scope 0 at $DIR/issue_41888.rs:+4:16: +4:24
|
|
|
|
+ let mut _7: bool; // in scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
|
|
|
|
+ let mut _8: bool; // in scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
|
|
|
|
+ let mut _9: bool; // in scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
|
|
|
|
+ let mut _10: isize; // in scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
|
|
|
|
+ let mut _11: isize; // in scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
|
|
|
|
scope 1 {
|
|
|
|
debug e => _1; // in scope 1 at $DIR/issue_41888.rs:+1:9: +1:10
|
|
|
|
scope 2 {
|
|
|
|
debug _k => _6; // in scope 2 at $DIR/issue_41888.rs:+4:21: +4:23
|
|
|
|
let _6: K; // in scope 2 at $DIR/issue_41888.rs:+4:21: +4:23
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
bb0: {
|
|
|
|
+ _9 = const false; // scope 0 at $DIR/issue_41888.rs:+1:9: +1:10
|
|
|
|
+ _7 = const false; // scope 0 at $DIR/issue_41888.rs:+1:9: +1:10
|
|
|
|
+ _8 = const false; // scope 0 at $DIR/issue_41888.rs:+1:9: +1:10
|
|
|
|
StorageLive(_1); // scope 0 at $DIR/issue_41888.rs:+1:9: +1:10
|
|
|
|
StorageLive(_2); // scope 1 at $DIR/issue_41888.rs:+2:8: +2:14
|
|
|
|
_2 = cond() -> [return: bb1, unwind: bb11]; // scope 1 at $DIR/issue_41888.rs:+2:8: +2:14
|
|
|
|
// mir::Constant
|
|
|
|
// + span: $DIR/issue_41888.rs:8:8: 8:12
|
|
|
|
// + literal: Const { ty: fn() -> bool {cond}, val: Value(<ZST>) }
|
|
|
|
}
|
|
|
|
|
|
|
|
bb1: {
|
2023-02-08 15:29:52 -06:00
|
|
|
switchInt(move _2) -> [0: bb8, otherwise: bb2]; // scope 1 at $DIR/issue_41888.rs:+2:8: +2:14
|
2023-02-22 18:00:00 -06:00
|
|
|
}
|
|
|
|
|
|
|
|
bb2: {
|
|
|
|
StorageLive(_3); // scope 1 at $DIR/issue_41888.rs:+3:13: +3:20
|
|
|
|
StorageLive(_4); // scope 1 at $DIR/issue_41888.rs:+3:18: +3:19
|
|
|
|
_4 = K; // scope 1 at $DIR/issue_41888.rs:+3:18: +3:19
|
|
|
|
_3 = E::F(move _4); // scope 1 at $DIR/issue_41888.rs:+3:13: +3:20
|
|
|
|
StorageDead(_4); // scope 1 at $DIR/issue_41888.rs:+3:19: +3:20
|
2023-02-08 15:29:52 -06:00
|
|
|
- drop(_1) -> [return: bb3, unwind: bb4]; // scope 1 at $DIR/issue_41888.rs:+3:9: +3:10
|
|
|
|
+ goto -> bb3; // scope 1 at $DIR/issue_41888.rs:+3:9: +3:10
|
2023-02-22 18:00:00 -06:00
|
|
|
}
|
|
|
|
|
|
|
|
bb3: {
|
2023-02-08 15:29:52 -06:00
|
|
|
+ _7 = const true; // scope 1 at $DIR/issue_41888.rs:+3:9: +3:10
|
|
|
|
+ _8 = const true; // scope 1 at $DIR/issue_41888.rs:+3:9: +3:10
|
|
|
|
+ _9 = const true; // scope 1 at $DIR/issue_41888.rs:+3:9: +3:10
|
|
|
|
_1 = move _3; // scope 1 at $DIR/issue_41888.rs:+3:9: +3:10
|
|
|
|
- drop(_3) -> [return: bb5, unwind: bb11]; // scope 1 at $DIR/issue_41888.rs:+3:19: +3:20
|
|
|
|
+ goto -> bb5; // scope 1 at $DIR/issue_41888.rs:+3:19: +3:20
|
|
|
|
}
|
|
|
|
|
|
|
|
bb4 (cleanup): {
|
|
|
|
_1 = move _3; // scope 1 at $DIR/issue_41888.rs:+3:9: +3:10
|
|
|
|
drop(_3) -> bb11; // scope 1 at $DIR/issue_41888.rs:+3:19: +3:20
|
2023-02-22 18:00:00 -06:00
|
|
|
}
|
|
|
|
|
2023-02-08 15:29:52 -06:00
|
|
|
bb5: {
|
2023-02-22 18:00:00 -06:00
|
|
|
StorageDead(_3); // scope 1 at $DIR/issue_41888.rs:+3:19: +3:20
|
|
|
|
_5 = discriminant(_1); // scope 2 at $DIR/issue_41888.rs:+4:16: +4:24
|
2023-02-08 15:29:52 -06:00
|
|
|
switchInt(move _5) -> [0: bb6, otherwise: bb7]; // scope 2 at $DIR/issue_41888.rs:+4:16: +4:24
|
2023-02-22 18:00:00 -06:00
|
|
|
}
|
|
|
|
|
2023-02-08 15:29:52 -06:00
|
|
|
bb6: {
|
2023-02-22 18:00:00 -06:00
|
|
|
StorageLive(_6); // scope 2 at $DIR/issue_41888.rs:+4:21: +4:23
|
|
|
|
+ _9 = const false; // scope 2 at $DIR/issue_41888.rs:+4:21: +4:23
|
|
|
|
_6 = move ((_1 as F).0: K); // scope 2 at $DIR/issue_41888.rs:+4:21: +4:23
|
|
|
|
_0 = const (); // scope 2 at $DIR/issue_41888.rs:+4:29: +7:10
|
|
|
|
StorageDead(_6); // scope 1 at $DIR/issue_41888.rs:+7:9: +7:10
|
2023-02-08 15:29:52 -06:00
|
|
|
goto -> bb9; // scope 1 at $DIR/issue_41888.rs:+4:9: +7:10
|
2023-02-22 18:00:00 -06:00
|
|
|
}
|
|
|
|
|
2023-02-08 15:29:52 -06:00
|
|
|
bb7: {
|
2023-02-22 18:00:00 -06:00
|
|
|
_0 = const (); // scope 1 at $DIR/issue_41888.rs:+7:10: +7:10
|
2023-02-08 15:29:52 -06:00
|
|
|
goto -> bb9; // scope 1 at $DIR/issue_41888.rs:+4:9: +7:10
|
2023-02-22 18:00:00 -06:00
|
|
|
}
|
|
|
|
|
2023-02-08 15:29:52 -06:00
|
|
|
bb8: {
|
2023-02-22 18:00:00 -06:00
|
|
|
_0 = const (); // scope 1 at $DIR/issue_41888.rs:+8:6: +8:6
|
2023-02-08 15:29:52 -06:00
|
|
|
goto -> bb9; // scope 1 at $DIR/issue_41888.rs:+2:5: +8:6
|
2023-02-22 18:00:00 -06:00
|
|
|
}
|
|
|
|
|
2023-02-08 15:29:52 -06:00
|
|
|
bb9: {
|
2023-02-22 18:00:00 -06:00
|
|
|
StorageDead(_2); // scope 1 at $DIR/issue_41888.rs:+8:5: +8:6
|
2023-02-08 15:29:52 -06:00
|
|
|
- drop(_1) -> bb10; // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
|
|
|
|
+ goto -> bb18; // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
|
2023-02-22 18:00:00 -06:00
|
|
|
}
|
|
|
|
|
2023-02-08 15:29:52 -06:00
|
|
|
bb10: {
|
2023-02-22 18:00:00 -06:00
|
|
|
+ _7 = const false; // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
|
|
|
|
+ _8 = const false; // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
|
|
|
|
+ _9 = const false; // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
|
|
|
|
StorageDead(_1); // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
|
|
|
|
return; // scope 0 at $DIR/issue_41888.rs:+9:2: +9:2
|
|
|
|
}
|
|
|
|
|
|
|
|
bb11 (cleanup): {
|
|
|
|
- drop(_1) -> bb12; // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
|
|
|
|
+ goto -> bb12; // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
|
|
|
|
}
|
|
|
|
|
|
|
|
bb12 (cleanup): {
|
|
|
|
resume; // scope 0 at $DIR/issue_41888.rs:+0:1: +9:2
|
|
|
|
+ }
|
|
|
|
+
|
2023-02-08 15:29:52 -06:00
|
|
|
+ bb13: {
|
2023-02-22 18:00:00 -06:00
|
|
|
+ _7 = const false; // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
|
2023-02-08 15:29:52 -06:00
|
|
|
+ goto -> bb10; // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
|
2023-02-22 18:00:00 -06:00
|
|
|
+ }
|
|
|
|
+
|
2023-02-08 15:29:52 -06:00
|
|
|
+ bb14 (cleanup): {
|
2023-02-22 18:00:00 -06:00
|
|
|
+ goto -> bb12; // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
|
|
|
|
+ }
|
|
|
|
+
|
2023-02-08 15:29:52 -06:00
|
|
|
+ bb15: {
|
|
|
|
+ drop(_1) -> [return: bb13, unwind: bb12]; // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
|
2023-02-22 18:00:00 -06:00
|
|
|
+ }
|
|
|
|
+
|
2023-02-08 15:29:52 -06:00
|
|
|
+ bb16 (cleanup): {
|
2023-02-22 18:00:00 -06:00
|
|
|
+ drop(_1) -> bb12; // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
|
|
|
|
+ }
|
|
|
|
+
|
2023-02-08 15:29:52 -06:00
|
|
|
+ bb17: {
|
2023-02-22 18:00:00 -06:00
|
|
|
+ _10 = discriminant(_1); // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
|
2023-02-08 15:29:52 -06:00
|
|
|
+ switchInt(move _10) -> [0: bb13, otherwise: bb15]; // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
|
2023-02-22 18:00:00 -06:00
|
|
|
+ }
|
|
|
|
+
|
2023-02-08 15:29:52 -06:00
|
|
|
+ bb18: {
|
|
|
|
+ switchInt(_7) -> [0: bb13, otherwise: bb17]; // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
|
2023-02-22 18:00:00 -06:00
|
|
|
+ }
|
|
|
|
+
|
2023-02-08 15:29:52 -06:00
|
|
|
+ bb19 (cleanup): {
|
2023-02-22 18:00:00 -06:00
|
|
|
+ _11 = discriminant(_1); // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
|
2023-02-08 15:29:52 -06:00
|
|
|
+ switchInt(move _11) -> [0: bb14, otherwise: bb16]; // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
|
2023-02-22 18:00:00 -06:00
|
|
|
+ }
|
|
|
|
+
|
2023-02-08 15:29:52 -06:00
|
|
|
+ bb20 (cleanup): {
|
|
|
|
+ switchInt(_7) -> [0: bb12, otherwise: bb19]; // scope 0 at $DIR/issue_41888.rs:+9:1: +9:2
|
2023-02-22 18:00:00 -06:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|