2020-10-03 04:18:24 -05:00
|
|
|
- // MIR for `f` before ConstGoto
|
|
|
|
+ // MIR for `f` after ConstGoto
|
|
|
|
|
|
|
|
fn f() -> u64 {
|
2022-07-27 13:47:42 -05:00
|
|
|
let mut _0: u64; // return place in scope 0 at $DIR/const_goto_const_eval_fail.rs:+0:44: +0:47
|
|
|
|
let mut _1: bool; // in scope 0 at $DIR/const_goto_const_eval_fail.rs:+1:11: +6:6
|
|
|
|
let mut _2: i32; // in scope 0 at $DIR/const_goto_const_eval_fail.rs:+2:15: +2:16
|
2020-10-03 04:18:24 -05:00
|
|
|
|
|
|
|
bb0: {
|
2022-07-27 13:47:42 -05:00
|
|
|
StorageLive(_1); // scope 0 at $DIR/const_goto_const_eval_fail.rs:+1:11: +6:6
|
|
|
|
StorageLive(_2); // scope 0 at $DIR/const_goto_const_eval_fail.rs:+2:15: +2:16
|
|
|
|
_2 = const A; // scope 0 at $DIR/const_goto_const_eval_fail.rs:+2:15: +2:16
|
2022-12-03 18:03:27 -06:00
|
|
|
switchInt(_2) -> [1: bb2, 2: bb2, 3: bb2, otherwise: bb1]; // scope 0 at $DIR/const_goto_const_eval_fail.rs:+2:9: +2:16
|
2020-10-03 04:18:24 -05:00
|
|
|
}
|
|
|
|
|
|
|
|
bb1: {
|
2022-07-27 13:47:42 -05:00
|
|
|
_1 = const true; // scope 0 at $DIR/const_goto_const_eval_fail.rs:+4:18: +4:22
|
|
|
|
goto -> bb3; // scope 0 at $DIR/const_goto_const_eval_fail.rs:+4:18: +4:22
|
2020-10-03 04:18:24 -05:00
|
|
|
}
|
|
|
|
|
|
|
|
bb2: {
|
2022-07-27 13:47:42 -05:00
|
|
|
_1 = const B; // scope 0 at $DIR/const_goto_const_eval_fail.rs:+3:26: +3:27
|
|
|
|
- goto -> bb3; // scope 0 at $DIR/const_goto_const_eval_fail.rs:+3:26: +3:27
|
2022-12-03 18:03:27 -06:00
|
|
|
+ switchInt(_1) -> [0: bb4, otherwise: bb3]; // scope 0 at $DIR/const_goto_const_eval_fail.rs:+1:5: +6:6
|
2020-10-03 04:18:24 -05:00
|
|
|
}
|
|
|
|
|
|
|
|
bb3: {
|
2022-12-03 18:03:27 -06:00
|
|
|
- switchInt(_1) -> [0: bb5, otherwise: bb4]; // scope 0 at $DIR/const_goto_const_eval_fail.rs:+1:5: +6:6
|
2020-10-03 04:18:24 -05:00
|
|
|
- }
|
|
|
|
-
|
|
|
|
- bb4: {
|
2022-07-27 13:47:42 -05:00
|
|
|
_0 = const 2_u64; // scope 0 at $DIR/const_goto_const_eval_fail.rs:+8:17: +8:18
|
|
|
|
- goto -> bb6; // scope 0 at $DIR/const_goto_const_eval_fail.rs:+8:17: +8:18
|
|
|
|
+ goto -> bb5; // scope 0 at $DIR/const_goto_const_eval_fail.rs:+8:17: +8:18
|
2020-10-03 04:18:24 -05:00
|
|
|
}
|
|
|
|
|
|
|
|
- bb5: {
|
|
|
|
+ bb4: {
|
2022-07-27 13:47:42 -05:00
|
|
|
_0 = const 1_u64; // scope 0 at $DIR/const_goto_const_eval_fail.rs:+7:18: +7:19
|
|
|
|
- goto -> bb6; // scope 0 at $DIR/const_goto_const_eval_fail.rs:+7:18: +7:19
|
|
|
|
+ goto -> bb5; // scope 0 at $DIR/const_goto_const_eval_fail.rs:+7:18: +7:19
|
2020-10-03 04:18:24 -05:00
|
|
|
}
|
|
|
|
|
|
|
|
- bb6: {
|
|
|
|
+ bb5: {
|
2022-07-27 13:47:42 -05:00
|
|
|
StorageDead(_2); // scope 0 at $DIR/const_goto_const_eval_fail.rs:+10:1: +10:2
|
|
|
|
StorageDead(_1); // scope 0 at $DIR/const_goto_const_eval_fail.rs:+10:1: +10:2
|
|
|
|
return; // scope 0 at $DIR/const_goto_const_eval_fail.rs:+10:2: +10:2
|
2020-10-03 04:18:24 -05:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|