2023-02-22 18:00:00 -06:00
|
|
|
- // MIR for `main` before ElaborateDrops
|
|
|
|
+ // MIR for `main` after ElaborateDrops
|
|
|
|
|
|
|
|
fn main() -> () {
|
2023-06-06 08:47:00 -05:00
|
|
|
let mut _0: ();
|
|
|
|
let _1: E;
|
|
|
|
let mut _2: bool;
|
|
|
|
let mut _3: E;
|
|
|
|
let mut _4: K;
|
|
|
|
let mut _5: isize;
|
|
|
|
+ let mut _7: bool;
|
|
|
|
+ let mut _8: bool;
|
2023-09-30 16:42:49 -05:00
|
|
|
+ let mut _9: isize;
|
2023-06-06 08:47:00 -05:00
|
|
|
+ let mut _10: isize;
|
2023-02-22 18:00:00 -06:00
|
|
|
scope 1 {
|
2023-06-06 08:47:00 -05:00
|
|
|
debug e => _1;
|
2023-02-22 18:00:00 -06:00
|
|
|
scope 2 {
|
2023-06-06 08:47:00 -05:00
|
|
|
debug _k => _6;
|
|
|
|
let _6: K;
|
2023-02-22 18:00:00 -06:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
bb0: {
|
2023-06-06 08:47:00 -05:00
|
|
|
+ _7 = const false;
|
|
|
|
+ _8 = const false;
|
|
|
|
StorageLive(_1);
|
|
|
|
StorageLive(_2);
|
|
|
|
_2 = cond() -> [return: bb1, unwind: bb11];
|
2023-02-22 18:00:00 -06:00
|
|
|
}
|
|
|
|
|
|
|
|
bb1: {
|
2023-06-06 08:47:00 -05:00
|
|
|
switchInt(move _2) -> [0: bb8, otherwise: bb2];
|
2023-02-22 18:00:00 -06:00
|
|
|
}
|
|
|
|
|
|
|
|
bb2: {
|
2023-06-06 08:47:00 -05:00
|
|
|
StorageLive(_3);
|
|
|
|
StorageLive(_4);
|
|
|
|
_4 = K;
|
|
|
|
_3 = E::F(move _4);
|
|
|
|
StorageDead(_4);
|
|
|
|
- drop(_1) -> [return: bb3, unwind: bb4];
|
|
|
|
+ goto -> bb3;
|
2023-02-22 18:00:00 -06:00
|
|
|
}
|
|
|
|
|
|
|
|
bb3: {
|
2023-06-06 08:47:00 -05:00
|
|
|
+ _7 = const true;
|
|
|
|
+ _8 = const true;
|
|
|
|
_1 = move _3;
|
|
|
|
- drop(_3) -> [return: bb5, unwind: bb11];
|
|
|
|
+ goto -> bb5;
|
2023-02-08 15:29:52 -06:00
|
|
|
}
|
|
|
|
|
|
|
|
bb4 (cleanup): {
|
2023-08-16 13:19:48 -05:00
|
|
|
+ _7 = const true;
|
|
|
|
+ _8 = const true;
|
2023-06-06 08:47:00 -05:00
|
|
|
_1 = move _3;
|
2023-08-24 07:26:26 -05:00
|
|
|
- drop(_3) -> [return: bb11, unwind terminate(cleanup)];
|
2023-08-16 13:19:48 -05:00
|
|
|
+ goto -> bb11;
|
2023-02-22 18:00:00 -06:00
|
|
|
}
|
|
|
|
|
2023-02-08 15:29:52 -06:00
|
|
|
bb5: {
|
2023-06-06 08:47:00 -05:00
|
|
|
StorageDead(_3);
|
2022-10-15 04:00:32 -05:00
|
|
|
PlaceMention(_1);
|
2023-06-06 08:47:00 -05:00
|
|
|
_5 = discriminant(_1);
|
|
|
|
switchInt(move _5) -> [0: bb6, otherwise: bb7];
|
2023-02-22 18:00:00 -06:00
|
|
|
}
|
|
|
|
|
2023-02-08 15:29:52 -06:00
|
|
|
bb6: {
|
2023-06-06 08:47:00 -05:00
|
|
|
StorageLive(_6);
|
|
|
|
_6 = move ((_1 as F).0: K);
|
|
|
|
_0 = const ();
|
|
|
|
StorageDead(_6);
|
|
|
|
goto -> bb9;
|
2023-02-22 18:00:00 -06:00
|
|
|
}
|
|
|
|
|
2023-02-08 15:29:52 -06:00
|
|
|
bb7: {
|
2023-06-06 08:47:00 -05:00
|
|
|
_0 = const ();
|
|
|
|
goto -> bb9;
|
2023-02-22 18:00:00 -06:00
|
|
|
}
|
|
|
|
|
2023-02-08 15:29:52 -06:00
|
|
|
bb8: {
|
2023-06-06 08:47:00 -05:00
|
|
|
_0 = const ();
|
|
|
|
goto -> bb9;
|
2023-02-22 18:00:00 -06:00
|
|
|
}
|
|
|
|
|
2023-02-08 15:29:52 -06:00
|
|
|
bb9: {
|
2023-06-06 08:47:00 -05:00
|
|
|
StorageDead(_2);
|
2023-06-23 11:53:09 -05:00
|
|
|
- drop(_1) -> [return: bb10, unwind continue];
|
2023-09-30 16:42:49 -05:00
|
|
|
+ goto -> bb19;
|
2023-02-22 18:00:00 -06:00
|
|
|
}
|
|
|
|
|
2023-02-08 15:29:52 -06:00
|
|
|
bb10: {
|
2023-06-06 08:47:00 -05:00
|
|
|
+ _7 = const false;
|
|
|
|
+ _8 = const false;
|
|
|
|
StorageDead(_1);
|
|
|
|
return;
|
2023-02-22 18:00:00 -06:00
|
|
|
}
|
|
|
|
|
|
|
|
bb11 (cleanup): {
|
2023-08-24 07:26:26 -05:00
|
|
|
- drop(_1) -> [return: bb12, unwind terminate(cleanup)];
|
2023-06-06 08:47:00 -05:00
|
|
|
+ goto -> bb12;
|
2023-02-22 18:00:00 -06:00
|
|
|
}
|
|
|
|
|
|
|
|
bb12 (cleanup): {
|
2023-06-06 08:47:00 -05:00
|
|
|
resume;
|
2023-02-22 18:00:00 -06:00
|
|
|
+ }
|
|
|
|
+
|
2023-05-06 02:57:05 -05:00
|
|
|
+ bb13: {
|
2023-06-06 08:47:00 -05:00
|
|
|
+ _7 = const false;
|
|
|
|
+ goto -> bb10;
|
2023-02-22 18:00:00 -06:00
|
|
|
+ }
|
|
|
|
+
|
2023-05-06 02:57:05 -05:00
|
|
|
+ bb14 (cleanup): {
|
2023-09-30 16:42:49 -05:00
|
|
|
+ drop(((_1 as F).0: K)) -> [return: bb12, unwind terminate(cleanup)];
|
2023-02-22 18:00:00 -06:00
|
|
|
+ }
|
|
|
|
+
|
2023-09-30 16:42:49 -05:00
|
|
|
+ bb15 (cleanup): {
|
|
|
|
+ switchInt(_7) -> [0: bb12, otherwise: bb14];
|
2023-02-22 18:00:00 -06:00
|
|
|
+ }
|
|
|
|
+
|
2023-09-30 16:42:49 -05:00
|
|
|
+ bb16: {
|
|
|
|
+ drop(_1) -> [return: bb13, unwind: bb12];
|
2023-02-22 18:00:00 -06:00
|
|
|
+ }
|
|
|
|
+
|
2023-09-30 16:42:49 -05:00
|
|
|
+ bb17 (cleanup): {
|
|
|
|
+ drop(_1) -> [return: bb12, unwind terminate(cleanup)];
|
2023-02-22 18:00:00 -06:00
|
|
|
+ }
|
|
|
|
+
|
2023-05-06 02:57:05 -05:00
|
|
|
+ bb18: {
|
2023-09-30 16:42:49 -05:00
|
|
|
+ _9 = discriminant(_1);
|
|
|
|
+ switchInt(move _9) -> [0: bb13, otherwise: bb16];
|
2023-02-22 18:00:00 -06:00
|
|
|
+ }
|
|
|
|
+
|
2023-09-30 16:42:49 -05:00
|
|
|
+ bb19: {
|
|
|
|
+ switchInt(_7) -> [0: bb13, otherwise: bb18];
|
2023-02-22 18:00:00 -06:00
|
|
|
+ }
|
|
|
|
+
|
2023-05-06 02:57:05 -05:00
|
|
|
+ bb20 (cleanup): {
|
2023-09-30 16:42:49 -05:00
|
|
|
+ _10 = discriminant(_1);
|
|
|
|
+ switchInt(move _10) -> [0: bb15, otherwise: bb17];
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ bb21 (cleanup): {
|
|
|
|
+ switchInt(_7) -> [0: bb12, otherwise: bb20];
|
2023-02-22 18:00:00 -06:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|