summaryrefslogtreecommitdiffstats
path: root/tests/mir-opt/building/while_storage.while_loop.PreCodegen.after.panic-unwind.mir
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-06-07 05:48:48 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-06-07 05:48:48 +0000
commitef24de24a82fe681581cc130f342363c47c0969a (patch)
tree0d494f7e1a38b95c92426f58fe6eaa877303a86c /tests/mir-opt/building/while_storage.while_loop.PreCodegen.after.panic-unwind.mir
parentReleasing progress-linux version 1.74.1+dfsg1-1~progress7.99u1. (diff)
downloadrustc-ef24de24a82fe681581cc130f342363c47c0969a.tar.xz
rustc-ef24de24a82fe681581cc130f342363c47c0969a.zip
Merging upstream version 1.75.0+dfsg1.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'tests/mir-opt/building/while_storage.while_loop.PreCodegen.after.panic-unwind.mir')
-rw-r--r--tests/mir-opt/building/while_storage.while_loop.PreCodegen.after.panic-unwind.mir70
1 files changed, 70 insertions, 0 deletions
diff --git a/tests/mir-opt/building/while_storage.while_loop.PreCodegen.after.panic-unwind.mir b/tests/mir-opt/building/while_storage.while_loop.PreCodegen.after.panic-unwind.mir
new file mode 100644
index 000000000..1bb720748
--- /dev/null
+++ b/tests/mir-opt/building/while_storage.while_loop.PreCodegen.after.panic-unwind.mir
@@ -0,0 +1,70 @@
+// MIR for `while_loop` after PreCodegen
+
+fn while_loop(_1: bool) -> () {
+ debug c => _1;
+ let mut _0: ();
+ let mut _2: bool;
+ let mut _3: bool;
+ let mut _4: bool;
+ let mut _5: bool;
+ let mut _6: ();
+ let mut _7: !;
+ let mut _8: !;
+ let _9: ();
+ let mut _10: !;
+
+ bb0: {
+ goto -> bb1;
+ }
+
+ bb1: {
+ StorageLive(_3);
+ StorageLive(_2);
+ _2 = _1;
+ _3 = get_bool(move _2) -> [return: bb2, unwind continue];
+ }
+
+ bb2: {
+ switchInt(move _3) -> [0: bb3, otherwise: bb4];
+ }
+
+ bb3: {
+ StorageDead(_2);
+ StorageLive(_9);
+ _0 = const ();
+ StorageDead(_9);
+ goto -> bb8;
+ }
+
+ bb4: {
+ StorageDead(_2);
+ StorageLive(_5);
+ StorageLive(_4);
+ _4 = _1;
+ _5 = get_bool(move _4) -> [return: bb5, unwind continue];
+ }
+
+ bb5: {
+ switchInt(move _5) -> [0: bb6, otherwise: bb7];
+ }
+
+ bb6: {
+ StorageDead(_4);
+ _6 = const ();
+ StorageDead(_5);
+ StorageDead(_3);
+ goto -> bb1;
+ }
+
+ bb7: {
+ StorageDead(_4);
+ _0 = const ();
+ StorageDead(_5);
+ goto -> bb8;
+ }
+
+ bb8: {
+ StorageDead(_3);
+ return;
+ }
+}