From 82d6e07c867046ad3e6dd6211c22213a91210eab Mon Sep 17 00:00:00 2001 From: Ana-Maria Mihalache Date: Wed, 8 Apr 2020 18:58:49 +0000 Subject: [PATCH] Add ignore-wasm32-bare to mir-opt tests that need it. --- src/test/mir-opt/issue-41888.rs | 1 + .../rustc.main.ElaborateDrops.after.mir | 180 ++++++------ src/test/mir-opt/match-arm-scopes.rs | 1 + ...complicated_match.ElaborateDrops.after.mir | 234 ++++++++-------- ...icated_match.SimplifyCfg-initial.after.mir | 262 +++++++++--------- 5 files changed, 340 insertions(+), 338 deletions(-) diff --git a/src/test/mir-opt/issue-41888.rs b/src/test/mir-opt/issue-41888.rs index 2c90f35ea6a49..6caaa59d0af34 100644 --- a/src/test/mir-opt/issue-41888.rs +++ b/src/test/mir-opt/issue-41888.rs @@ -1,3 +1,4 @@ +// ignore-wasm32-bare compiled with panic=abort by default // check that we clear the "ADT master drop flag" even when there are // no fields to be dropped. diff --git a/src/test/mir-opt/issue-41888/rustc.main.ElaborateDrops.after.mir b/src/test/mir-opt/issue-41888/rustc.main.ElaborateDrops.after.mir index ba2f65be3652f..6cd3e2dec838c 100644 --- a/src/test/mir-opt/issue-41888/rustc.main.ElaborateDrops.after.mir +++ b/src/test/mir-opt/issue-41888/rustc.main.ElaborateDrops.after.mir @@ -1,250 +1,250 @@ // MIR for `main` after ElaborateDrops fn main() -> () { - let mut _0: (); // return place in scope 0 at $DIR/issue-41888.rs:5:11: 5:11 - let _1: E; // in scope 0 at $DIR/issue-41888.rs:6:9: 6:10 - let mut _2: bool; // in scope 0 at $DIR/issue-41888.rs:7:8: 7:14 - let mut _3: E; // in scope 0 at $DIR/issue-41888.rs:8:13: 8:20 - let mut _4: K; // in scope 0 at $DIR/issue-41888.rs:8:18: 8:19 - let mut _5: isize; // in scope 0 at $DIR/issue-41888.rs:9:16: 9:24 - let mut _7: bool; // in scope 0 at $DIR/issue-41888.rs:14:1: 14:2 - let mut _8: bool; // in scope 0 at $DIR/issue-41888.rs:14:1: 14:2 - let mut _9: bool; // in scope 0 at $DIR/issue-41888.rs:14:1: 14:2 - let mut _10: isize; // in scope 0 at $DIR/issue-41888.rs:14:1: 14:2 - let mut _11: isize; // in scope 0 at $DIR/issue-41888.rs:14:1: 14:2 + let mut _0: (); // return place in scope 0 at $DIR/issue-41888.rs:6:11: 6:11 + let _1: E; // in scope 0 at $DIR/issue-41888.rs:7:9: 7:10 + let mut _2: bool; // in scope 0 at $DIR/issue-41888.rs:8:8: 8:14 + let mut _3: E; // in scope 0 at $DIR/issue-41888.rs:9:13: 9:20 + let mut _4: K; // in scope 0 at $DIR/issue-41888.rs:9:18: 9:19 + let mut _5: isize; // in scope 0 at $DIR/issue-41888.rs:10:16: 10:24 + let mut _7: bool; // in scope 0 at $DIR/issue-41888.rs:15:1: 15:2 + let mut _8: bool; // in scope 0 at $DIR/issue-41888.rs:15:1: 15:2 + let mut _9: bool; // in scope 0 at $DIR/issue-41888.rs:15:1: 15:2 + let mut _10: isize; // in scope 0 at $DIR/issue-41888.rs:15:1: 15:2 + let mut _11: isize; // in scope 0 at $DIR/issue-41888.rs:15:1: 15:2 scope 1 { - debug e => _1; // in scope 1 at $DIR/issue-41888.rs:6:9: 6:10 - let _6: K; // in scope 1 at $DIR/issue-41888.rs:9:21: 9:23 + debug e => _1; // in scope 1 at $DIR/issue-41888.rs:7:9: 7:10 + let _6: K; // in scope 1 at $DIR/issue-41888.rs:10:21: 10:23 scope 2 { - debug _k => _6; // in scope 2 at $DIR/issue-41888.rs:9:21: 9:23 + debug _k => _6; // in scope 2 at $DIR/issue-41888.rs:10:21: 10:23 } } bb0: { - _9 = const false; // bb0[0]: scope 0 at $DIR/issue-41888.rs:6:9: 6:10 + _9 = const false; // bb0[0]: scope 0 at $DIR/issue-41888.rs:7:9: 7:10 // ty::Const // + ty: bool // + val: Value(Scalar(0x00)) // mir::Constant - // + span: $DIR/issue-41888.rs:6:9: 6:10 + // + span: $DIR/issue-41888.rs:7:9: 7:10 // + literal: Const { ty: bool, val: Value(Scalar(0x00)) } - _7 = const false; // bb0[1]: scope 0 at $DIR/issue-41888.rs:6:9: 6:10 + _7 = const false; // bb0[1]: scope 0 at $DIR/issue-41888.rs:7:9: 7:10 // ty::Const // + ty: bool // + val: Value(Scalar(0x00)) // mir::Constant - // + span: $DIR/issue-41888.rs:6:9: 6:10 + // + span: $DIR/issue-41888.rs:7:9: 7:10 // + literal: Const { ty: bool, val: Value(Scalar(0x00)) } - _8 = const false; // bb0[2]: scope 0 at $DIR/issue-41888.rs:6:9: 6:10 + _8 = const false; // bb0[2]: scope 0 at $DIR/issue-41888.rs:7:9: 7:10 // ty::Const // + ty: bool // + val: Value(Scalar(0x00)) // mir::Constant - // + span: $DIR/issue-41888.rs:6:9: 6:10 + // + span: $DIR/issue-41888.rs:7:9: 7:10 // + literal: Const { ty: bool, val: Value(Scalar(0x00)) } - StorageLive(_1); // bb0[3]: scope 0 at $DIR/issue-41888.rs:6:9: 6:10 - StorageLive(_2); // bb0[4]: scope 1 at $DIR/issue-41888.rs:7:8: 7:14 - _2 = const cond() -> [return: bb2, unwind: bb3]; // bb0[5]: scope 1 at $DIR/issue-41888.rs:7:8: 7:14 + StorageLive(_1); // bb0[3]: scope 0 at $DIR/issue-41888.rs:7:9: 7:10 + StorageLive(_2); // bb0[4]: scope 1 at $DIR/issue-41888.rs:8:8: 8:14 + _2 = const cond() -> [return: bb2, unwind: bb3]; // bb0[5]: scope 1 at $DIR/issue-41888.rs:8:8: 8:14 // ty::Const // + ty: fn() -> bool {cond} // + val: Value(Scalar()) // mir::Constant - // + span: $DIR/issue-41888.rs:7:8: 7:12 + // + span: $DIR/issue-41888.rs:8:8: 8:12 // + literal: Const { ty: fn() -> bool {cond}, val: Value(Scalar()) } } bb1 (cleanup): { - resume; // bb1[0]: scope 0 at $DIR/issue-41888.rs:5:1: 14:2 + resume; // bb1[0]: scope 0 at $DIR/issue-41888.rs:6:1: 15:2 } bb2: { - switchInt(_2) -> [false: bb4, otherwise: bb5]; // bb2[0]: scope 1 at $DIR/issue-41888.rs:7:5: 13:6 + switchInt(_2) -> [false: bb4, otherwise: bb5]; // bb2[0]: scope 1 at $DIR/issue-41888.rs:8:5: 14:6 } bb3 (cleanup): { - goto -> bb1; // bb3[0]: scope 0 at $DIR/issue-41888.rs:14:1: 14:2 + goto -> bb1; // bb3[0]: scope 0 at $DIR/issue-41888.rs:15:1: 15:2 } bb4: { - _0 = (); // bb4[0]: scope 1 at $DIR/issue-41888.rs:7:5: 13:6 - goto -> bb11; // bb4[1]: scope 1 at $DIR/issue-41888.rs:7:5: 13:6 + _0 = (); // bb4[0]: scope 1 at $DIR/issue-41888.rs:8:5: 14:6 + goto -> bb11; // bb4[1]: scope 1 at $DIR/issue-41888.rs:8:5: 14:6 } bb5: { - StorageLive(_3); // bb5[0]: scope 1 at $DIR/issue-41888.rs:8:13: 8:20 - StorageLive(_4); // bb5[1]: scope 1 at $DIR/issue-41888.rs:8:18: 8:19 - _4 = K; // bb5[2]: scope 1 at $DIR/issue-41888.rs:8:18: 8:19 - _3 = E::F(move _4,); // bb5[3]: scope 1 at $DIR/issue-41888.rs:8:13: 8:20 - StorageDead(_4); // bb5[4]: scope 1 at $DIR/issue-41888.rs:8:19: 8:20 - goto -> bb14; // bb5[5]: scope 1 at $DIR/issue-41888.rs:8:9: 8:10 + StorageLive(_3); // bb5[0]: scope 1 at $DIR/issue-41888.rs:9:13: 9:20 + StorageLive(_4); // bb5[1]: scope 1 at $DIR/issue-41888.rs:9:18: 9:19 + _4 = K; // bb5[2]: scope 1 at $DIR/issue-41888.rs:9:18: 9:19 + _3 = E::F(move _4,); // bb5[3]: scope 1 at $DIR/issue-41888.rs:9:13: 9:20 + StorageDead(_4); // bb5[4]: scope 1 at $DIR/issue-41888.rs:9:19: 9:20 + goto -> bb14; // bb5[5]: scope 1 at $DIR/issue-41888.rs:9:9: 9:10 } bb6: { - goto -> bb8; // bb6[0]: scope 1 at $DIR/issue-41888.rs:8:19: 8:20 + goto -> bb8; // bb6[0]: scope 1 at $DIR/issue-41888.rs:9:19: 9:20 } bb7 (cleanup): { - goto -> bb3; // bb7[0]: scope 1 at $DIR/issue-41888.rs:8:19: 8:20 + goto -> bb3; // bb7[0]: scope 1 at $DIR/issue-41888.rs:9:19: 9:20 } bb8: { - StorageDead(_3); // bb8[0]: scope 1 at $DIR/issue-41888.rs:8:19: 8:20 - _5 = discriminant(_1); // bb8[1]: scope 1 at $DIR/issue-41888.rs:9:16: 9:24 - switchInt(move _5) -> [0isize: bb10, otherwise: bb9]; // bb8[2]: scope 1 at $DIR/issue-41888.rs:9:16: 9:24 + StorageDead(_3); // bb8[0]: scope 1 at $DIR/issue-41888.rs:9:19: 9:20 + _5 = discriminant(_1); // bb8[1]: scope 1 at $DIR/issue-41888.rs:10:16: 10:24 + switchInt(move _5) -> [0isize: bb10, otherwise: bb9]; // bb8[2]: scope 1 at $DIR/issue-41888.rs:10:16: 10:24 } bb9: { - _0 = (); // bb9[0]: scope 1 at $DIR/issue-41888.rs:9:9: 12:10 - goto -> bb11; // bb9[1]: scope 1 at $DIR/issue-41888.rs:9:9: 12:10 + _0 = (); // bb9[0]: scope 1 at $DIR/issue-41888.rs:10:9: 13:10 + goto -> bb11; // bb9[1]: scope 1 at $DIR/issue-41888.rs:10:9: 13:10 } bb10: { - StorageLive(_6); // bb10[0]: scope 1 at $DIR/issue-41888.rs:9:21: 9:23 - _9 = const false; // bb10[1]: scope 1 at $DIR/issue-41888.rs:9:21: 9:23 + StorageLive(_6); // bb10[0]: scope 1 at $DIR/issue-41888.rs:10:21: 10:23 + _9 = const false; // bb10[1]: scope 1 at $DIR/issue-41888.rs:10:21: 10:23 // ty::Const // + ty: bool // + val: Value(Scalar(0x00)) // mir::Constant - // + span: $DIR/issue-41888.rs:9:21: 9:23 + // + span: $DIR/issue-41888.rs:10:21: 10:23 // + literal: Const { ty: bool, val: Value(Scalar(0x00)) } - _6 = move ((_1 as F).0: K); // bb10[2]: scope 1 at $DIR/issue-41888.rs:9:21: 9:23 - _0 = (); // bb10[3]: scope 2 at $DIR/issue-41888.rs:9:29: 12:10 - StorageDead(_6); // bb10[4]: scope 1 at $DIR/issue-41888.rs:12:9: 12:10 - goto -> bb11; // bb10[5]: scope 1 at $DIR/issue-41888.rs:9:9: 12:10 + _6 = move ((_1 as F).0: K); // bb10[2]: scope 1 at $DIR/issue-41888.rs:10:21: 10:23 + _0 = (); // bb10[3]: scope 2 at $DIR/issue-41888.rs:10:29: 13:10 + StorageDead(_6); // bb10[4]: scope 1 at $DIR/issue-41888.rs:13:9: 13:10 + goto -> bb11; // bb10[5]: scope 1 at $DIR/issue-41888.rs:10:9: 13:10 } bb11: { - goto -> bb21; // bb11[0]: scope 0 at $DIR/issue-41888.rs:14:1: 14:2 + goto -> bb21; // bb11[0]: scope 0 at $DIR/issue-41888.rs:15:1: 15:2 } bb12: { - _7 = const false; // bb12[0]: scope 0 at $DIR/issue-41888.rs:14:1: 14:2 + _7 = const false; // bb12[0]: scope 0 at $DIR/issue-41888.rs:15:1: 15:2 // ty::Const // + ty: bool // + val: Value(Scalar(0x00)) // mir::Constant - // + span: $DIR/issue-41888.rs:14:1: 14:2 + // + span: $DIR/issue-41888.rs:15:1: 15:2 // + literal: Const { ty: bool, val: Value(Scalar(0x00)) } - _8 = const false; // bb12[1]: scope 0 at $DIR/issue-41888.rs:14:1: 14:2 + _8 = const false; // bb12[1]: scope 0 at $DIR/issue-41888.rs:15:1: 15:2 // ty::Const // + ty: bool // + val: Value(Scalar(0x00)) // mir::Constant - // + span: $DIR/issue-41888.rs:14:1: 14:2 + // + span: $DIR/issue-41888.rs:15:1: 15:2 // + literal: Const { ty: bool, val: Value(Scalar(0x00)) } - _9 = const false; // bb12[2]: scope 0 at $DIR/issue-41888.rs:14:1: 14:2 + _9 = const false; // bb12[2]: scope 0 at $DIR/issue-41888.rs:15:1: 15:2 // ty::Const // + ty: bool // + val: Value(Scalar(0x00)) // mir::Constant - // + span: $DIR/issue-41888.rs:14:1: 14:2 + // + span: $DIR/issue-41888.rs:15:1: 15:2 // + literal: Const { ty: bool, val: Value(Scalar(0x00)) } - StorageDead(_1); // bb12[3]: scope 0 at $DIR/issue-41888.rs:14:1: 14:2 - StorageDead(_2); // bb12[4]: scope 0 at $DIR/issue-41888.rs:14:1: 14:2 - return; // bb12[5]: scope 0 at $DIR/issue-41888.rs:14:2: 14:2 + StorageDead(_1); // bb12[3]: scope 0 at $DIR/issue-41888.rs:15:1: 15:2 + StorageDead(_2); // bb12[4]: scope 0 at $DIR/issue-41888.rs:15:1: 15:2 + return; // bb12[5]: scope 0 at $DIR/issue-41888.rs:15:2: 15:2 } bb13 (cleanup): { - _7 = const true; // bb13[0]: scope 1 at $DIR/issue-41888.rs:8:9: 8:10 + _7 = const true; // bb13[0]: scope 1 at $DIR/issue-41888.rs:9:9: 9:10 // ty::Const // + ty: bool // + val: Value(Scalar(0x01)) // mir::Constant - // + span: $DIR/issue-41888.rs:8:9: 8:10 + // + span: $DIR/issue-41888.rs:9:9: 9:10 // + literal: Const { ty: bool, val: Value(Scalar(0x01)) } - _8 = const true; // bb13[1]: scope 1 at $DIR/issue-41888.rs:8:9: 8:10 + _8 = const true; // bb13[1]: scope 1 at $DIR/issue-41888.rs:9:9: 9:10 // ty::Const // + ty: bool // + val: Value(Scalar(0x01)) // mir::Constant - // + span: $DIR/issue-41888.rs:8:9: 8:10 + // + span: $DIR/issue-41888.rs:9:9: 9:10 // + literal: Const { ty: bool, val: Value(Scalar(0x01)) } - _9 = const true; // bb13[2]: scope 1 at $DIR/issue-41888.rs:8:9: 8:10 + _9 = const true; // bb13[2]: scope 1 at $DIR/issue-41888.rs:9:9: 9:10 // ty::Const // + ty: bool // + val: Value(Scalar(0x01)) // mir::Constant - // + span: $DIR/issue-41888.rs:8:9: 8:10 + // + span: $DIR/issue-41888.rs:9:9: 9:10 // + literal: Const { ty: bool, val: Value(Scalar(0x01)) } - _1 = move _3; // bb13[3]: scope 1 at $DIR/issue-41888.rs:8:9: 8:10 - goto -> bb7; // bb13[4]: scope 1 at $DIR/issue-41888.rs:8:9: 8:10 + _1 = move _3; // bb13[3]: scope 1 at $DIR/issue-41888.rs:9:9: 9:10 + goto -> bb7; // bb13[4]: scope 1 at $DIR/issue-41888.rs:9:9: 9:10 } bb14: { - _7 = const true; // bb14[0]: scope 1 at $DIR/issue-41888.rs:8:9: 8:10 + _7 = const true; // bb14[0]: scope 1 at $DIR/issue-41888.rs:9:9: 9:10 // ty::Const // + ty: bool // + val: Value(Scalar(0x01)) // mir::Constant - // + span: $DIR/issue-41888.rs:8:9: 8:10 + // + span: $DIR/issue-41888.rs:9:9: 9:10 // + literal: Const { ty: bool, val: Value(Scalar(0x01)) } - _8 = const true; // bb14[1]: scope 1 at $DIR/issue-41888.rs:8:9: 8:10 + _8 = const true; // bb14[1]: scope 1 at $DIR/issue-41888.rs:9:9: 9:10 // ty::Const // + ty: bool // + val: Value(Scalar(0x01)) // mir::Constant - // + span: $DIR/issue-41888.rs:8:9: 8:10 + // + span: $DIR/issue-41888.rs:9:9: 9:10 // + literal: Const { ty: bool, val: Value(Scalar(0x01)) } - _9 = const true; // bb14[2]: scope 1 at $DIR/issue-41888.rs:8:9: 8:10 + _9 = const true; // bb14[2]: scope 1 at $DIR/issue-41888.rs:9:9: 9:10 // ty::Const // + ty: bool // + val: Value(Scalar(0x01)) // mir::Constant - // + span: $DIR/issue-41888.rs:8:9: 8:10 + // + span: $DIR/issue-41888.rs:9:9: 9:10 // + literal: Const { ty: bool, val: Value(Scalar(0x01)) } - _1 = move _3; // bb14[3]: scope 1 at $DIR/issue-41888.rs:8:9: 8:10 - goto -> bb6; // bb14[4]: scope 1 at $DIR/issue-41888.rs:8:9: 8:10 + _1 = move _3; // bb14[3]: scope 1 at $DIR/issue-41888.rs:9:9: 9:10 + goto -> bb6; // bb14[4]: scope 1 at $DIR/issue-41888.rs:9:9: 9:10 } bb15: { - _7 = const false; // bb15[0]: scope 0 at $DIR/issue-41888.rs:14:1: 14:2 + _7 = const false; // bb15[0]: scope 0 at $DIR/issue-41888.rs:15:1: 15:2 // ty::Const // + ty: bool // + val: Value(Scalar(0x00)) // mir::Constant - // + span: $DIR/issue-41888.rs:14:1: 14:2 + // + span: $DIR/issue-41888.rs:15:1: 15:2 // + literal: Const { ty: bool, val: Value(Scalar(0x00)) } - goto -> bb12; // bb15[1]: scope 0 at $DIR/issue-41888.rs:14:1: 14:2 + goto -> bb12; // bb15[1]: scope 0 at $DIR/issue-41888.rs:15:1: 15:2 } bb16 (cleanup): { - _7 = const false; // bb16[0]: scope 0 at $DIR/issue-41888.rs:14:1: 14:2 + _7 = const false; // bb16[0]: scope 0 at $DIR/issue-41888.rs:15:1: 15:2 // ty::Const // + ty: bool // + val: Value(Scalar(0x00)) // mir::Constant - // + span: $DIR/issue-41888.rs:14:1: 14:2 + // + span: $DIR/issue-41888.rs:15:1: 15:2 // + literal: Const { ty: bool, val: Value(Scalar(0x00)) } - goto -> bb1; // bb16[1]: scope 0 at $DIR/issue-41888.rs:14:1: 14:2 + goto -> bb1; // bb16[1]: scope 0 at $DIR/issue-41888.rs:15:1: 15:2 } bb17 (cleanup): { - goto -> bb16; // bb17[0]: scope 0 at $DIR/issue-41888.rs:14:1: 14:2 + goto -> bb16; // bb17[0]: scope 0 at $DIR/issue-41888.rs:15:1: 15:2 } bb18: { - drop(_1) -> [return: bb15, unwind: bb16]; // bb18[0]: scope 0 at $DIR/issue-41888.rs:14:1: 14:2 + drop(_1) -> [return: bb15, unwind: bb16]; // bb18[0]: scope 0 at $DIR/issue-41888.rs:15:1: 15:2 } bb19 (cleanup): { - drop(_1) -> bb16; // bb19[0]: scope 0 at $DIR/issue-41888.rs:14:1: 14:2 + drop(_1) -> bb16; // bb19[0]: scope 0 at $DIR/issue-41888.rs:15:1: 15:2 } bb20: { - _10 = discriminant(_1); // bb20[0]: scope 0 at $DIR/issue-41888.rs:14:1: 14:2 - switchInt(move _10) -> [0isize: bb15, otherwise: bb18]; // bb20[1]: scope 0 at $DIR/issue-41888.rs:14:1: 14:2 + _10 = discriminant(_1); // bb20[0]: scope 0 at $DIR/issue-41888.rs:15:1: 15:2 + switchInt(move _10) -> [0isize: bb15, otherwise: bb18]; // bb20[1]: scope 0 at $DIR/issue-41888.rs:15:1: 15:2 } bb21: { - switchInt(_7) -> [false: bb15, otherwise: bb20]; // bb21[0]: scope 0 at $DIR/issue-41888.rs:14:1: 14:2 + switchInt(_7) -> [false: bb15, otherwise: bb20]; // bb21[0]: scope 0 at $DIR/issue-41888.rs:15:1: 15:2 } bb22 (cleanup): { - _11 = discriminant(_1); // bb22[0]: scope 0 at $DIR/issue-41888.rs:14:1: 14:2 - switchInt(move _11) -> [0isize: bb17, otherwise: bb19]; // bb22[1]: scope 0 at $DIR/issue-41888.rs:14:1: 14:2 + _11 = discriminant(_1); // bb22[0]: scope 0 at $DIR/issue-41888.rs:15:1: 15:2 + switchInt(move _11) -> [0isize: bb17, otherwise: bb19]; // bb22[1]: scope 0 at $DIR/issue-41888.rs:15:1: 15:2 } bb23 (cleanup): { - switchInt(_7) -> [false: bb16, otherwise: bb22]; // bb23[0]: scope 0 at $DIR/issue-41888.rs:14:1: 14:2 + switchInt(_7) -> [false: bb16, otherwise: bb22]; // bb23[0]: scope 0 at $DIR/issue-41888.rs:15:1: 15:2 } } diff --git a/src/test/mir-opt/match-arm-scopes.rs b/src/test/mir-opt/match-arm-scopes.rs index 8efca2dd7abb5..0e30a15671528 100644 --- a/src/test/mir-opt/match-arm-scopes.rs +++ b/src/test/mir-opt/match-arm-scopes.rs @@ -1,3 +1,4 @@ +// ignore-wasm32-bare compiled with panic=abort by default // Test that StorageDead and Drops are generated properly for bindings in // matches: // * The MIR should only contain a single drop of `s` and `t`: at the end diff --git a/src/test/mir-opt/match-arm-scopes/rustc.complicated_match.ElaborateDrops.after.mir b/src/test/mir-opt/match-arm-scopes/rustc.complicated_match.ElaborateDrops.after.mir index 807df5be31ade..0b60f4f3321b6 100644 --- a/src/test/mir-opt/match-arm-scopes/rustc.complicated_match.ElaborateDrops.after.mir +++ b/src/test/mir-opt/match-arm-scopes/rustc.complicated_match.ElaborateDrops.after.mir @@ -1,235 +1,235 @@ // MIR for `complicated_match` after ElaborateDrops fn complicated_match(_1: bool, _2: (bool, bool, std::string::String)) -> i32 { - debug cond => _1; // in scope 0 at $DIR/match-arm-scopes.rs:13:22: 13:26 - debug items => _2; // in scope 0 at $DIR/match-arm-scopes.rs:13:34: 13:39 - let mut _0: i32; // return place in scope 0 at $DIR/match-arm-scopes.rs:13:66: 13:69 - let mut _3: &bool; // in scope 0 at $DIR/match-arm-scopes.rs:14:11: 14:16 - let mut _4: &bool; // in scope 0 at $DIR/match-arm-scopes.rs:14:11: 14:16 - let _5: bool; // in scope 0 at $DIR/match-arm-scopes.rs:15:17: 15:18 - let _6: &bool; // in scope 0 at $DIR/match-arm-scopes.rs:15:17: 15:18 - let _7: std::string::String; // in scope 0 at $DIR/match-arm-scopes.rs:15:20: 15:21 - let _8: &std::string::String; // in scope 0 at $DIR/match-arm-scopes.rs:15:20: 15:21 - let mut _9: bool; // in scope 0 at $DIR/match-arm-scopes.rs:15:42: 15:73 - let mut _10: bool; // in scope 0 at $DIR/match-arm-scopes.rs:15:45: 15:49 - let mut _11: !; // in scope 0 at $DIR/match-arm-scopes.rs:15:52: 15:60 - let mut _12: bool; // in scope 0 at $DIR/match-arm-scopes.rs:15:42: 15:73 - let mut _13: bool; // in scope 0 at $DIR/match-arm-scopes.rs:15:45: 15:49 - let mut _14: !; // in scope 0 at $DIR/match-arm-scopes.rs:15:52: 15:60 - let _15: bool; // in scope 0 at $DIR/match-arm-scopes.rs:16:16: 16:17 - let _16: std::string::String; // in scope 0 at $DIR/match-arm-scopes.rs:16:19: 16:20 + debug cond => _1; // in scope 0 at $DIR/match-arm-scopes.rs:14:22: 14:26 + debug items => _2; // in scope 0 at $DIR/match-arm-scopes.rs:14:34: 14:39 + let mut _0: i32; // return place in scope 0 at $DIR/match-arm-scopes.rs:14:66: 14:69 + let mut _3: &bool; // in scope 0 at $DIR/match-arm-scopes.rs:15:11: 15:16 + let mut _4: &bool; // in scope 0 at $DIR/match-arm-scopes.rs:15:11: 15:16 + let _5: bool; // in scope 0 at $DIR/match-arm-scopes.rs:16:17: 16:18 + let _6: &bool; // in scope 0 at $DIR/match-arm-scopes.rs:16:17: 16:18 + let _7: std::string::String; // in scope 0 at $DIR/match-arm-scopes.rs:16:20: 16:21 + let _8: &std::string::String; // in scope 0 at $DIR/match-arm-scopes.rs:16:20: 16:21 + let mut _9: bool; // in scope 0 at $DIR/match-arm-scopes.rs:16:42: 16:73 + let mut _10: bool; // in scope 0 at $DIR/match-arm-scopes.rs:16:45: 16:49 + let mut _11: !; // in scope 0 at $DIR/match-arm-scopes.rs:16:52: 16:60 + let mut _12: bool; // in scope 0 at $DIR/match-arm-scopes.rs:16:42: 16:73 + let mut _13: bool; // in scope 0 at $DIR/match-arm-scopes.rs:16:45: 16:49 + let mut _14: !; // in scope 0 at $DIR/match-arm-scopes.rs:16:52: 16:60 + let _15: bool; // in scope 0 at $DIR/match-arm-scopes.rs:17:16: 17:17 + let _16: std::string::String; // in scope 0 at $DIR/match-arm-scopes.rs:17:19: 17:20 scope 1 { - debug a => _5; // in scope 1 at $DIR/match-arm-scopes.rs:15:17: 15:18 - debug a => _6; // in scope 1 at $DIR/match-arm-scopes.rs:15:17: 15:18 - debug s => _7; // in scope 1 at $DIR/match-arm-scopes.rs:15:20: 15:21 - debug s => _8; // in scope 1 at $DIR/match-arm-scopes.rs:15:20: 15:21 + debug a => _5; // in scope 1 at $DIR/match-arm-scopes.rs:16:17: 16:18 + debug a => _6; // in scope 1 at $DIR/match-arm-scopes.rs:16:17: 16:18 + debug s => _7; // in scope 1 at $DIR/match-arm-scopes.rs:16:20: 16:21 + debug s => _8; // in scope 1 at $DIR/match-arm-scopes.rs:16:20: 16:21 } scope 2 { - debug b => _15; // in scope 2 at $DIR/match-arm-scopes.rs:16:16: 16:17 - debug t => _16; // in scope 2 at $DIR/match-arm-scopes.rs:16:19: 16:20 + debug b => _15; // in scope 2 at $DIR/match-arm-scopes.rs:17:16: 17:17 + debug t => _16; // in scope 2 at $DIR/match-arm-scopes.rs:17:19: 17:20 } bb0: { - switchInt((_2.0: bool)) -> [false: bb6, otherwise: bb2]; // bb0[0]: scope 0 at $DIR/match-arm-scopes.rs:15:10: 15:15 + switchInt((_2.0: bool)) -> [false: bb6, otherwise: bb2]; // bb0[0]: scope 0 at $DIR/match-arm-scopes.rs:16:10: 16:15 } bb1 (cleanup): { - resume; // bb1[0]: scope 0 at $DIR/match-arm-scopes.rs:13:1: 18:2 + resume; // bb1[0]: scope 0 at $DIR/match-arm-scopes.rs:14:1: 19:2 } bb2: { - switchInt((_2.1: bool)) -> [false: bb14, otherwise: bb3]; // bb2[0]: scope 0 at $DIR/match-arm-scopes.rs:15:29: 15:34 + switchInt((_2.1: bool)) -> [false: bb14, otherwise: bb3]; // bb2[0]: scope 0 at $DIR/match-arm-scopes.rs:16:29: 16:34 } bb3: { - switchInt((_2.0: bool)) -> [false: bb4, otherwise: bb21]; // bb3[0]: scope 0 at $DIR/match-arm-scopes.rs:16:10: 16:14 + switchInt((_2.0: bool)) -> [false: bb4, otherwise: bb21]; // bb3[0]: scope 0 at $DIR/match-arm-scopes.rs:17:10: 17:14 } bb4: { - StorageLive(_15); // bb4[0]: scope 0 at $DIR/match-arm-scopes.rs:16:32: 16:33 - _15 = (_2.1: bool); // bb4[1]: scope 0 at $DIR/match-arm-scopes.rs:16:32: 16:33 - StorageLive(_16); // bb4[2]: scope 0 at $DIR/match-arm-scopes.rs:16:35: 16:36 - _16 = move (_2.2: std::string::String); // bb4[3]: scope 0 at $DIR/match-arm-scopes.rs:16:35: 16:36 - goto -> bb20; // bb4[4]: scope 0 at $DIR/match-arm-scopes.rs:14:5: 17:6 + StorageLive(_15); // bb4[0]: scope 0 at $DIR/match-arm-scopes.rs:17:32: 17:33 + _15 = (_2.1: bool); // bb4[1]: scope 0 at $DIR/match-arm-scopes.rs:17:32: 17:33 + StorageLive(_16); // bb4[2]: scope 0 at $DIR/match-arm-scopes.rs:17:35: 17:36 + _16 = move (_2.2: std::string::String); // bb4[3]: scope 0 at $DIR/match-arm-scopes.rs:17:35: 17:36 + goto -> bb20; // bb4[4]: scope 0 at $DIR/match-arm-scopes.rs:15:5: 18:6 } bb5: { - _0 = const 1i32; // bb5[0]: scope 1 at $DIR/match-arm-scopes.rs:15:77: 15:78 + _0 = const 1i32; // bb5[0]: scope 1 at $DIR/match-arm-scopes.rs:16:77: 16:78 // ty::Const // + ty: i32 // + val: Value(Scalar(0x00000001)) // mir::Constant - // + span: $DIR/match-arm-scopes.rs:15:77: 15:78 + // + span: $DIR/match-arm-scopes.rs:16:77: 16:78 // + literal: Const { ty: i32, val: Value(Scalar(0x00000001)) } - drop(_7) -> [return: bb19, unwind: bb10]; // bb5[1]: scope 0 at $DIR/match-arm-scopes.rs:15:78: 15:79 + drop(_7) -> [return: bb19, unwind: bb10]; // bb5[1]: scope 0 at $DIR/match-arm-scopes.rs:16:78: 16:79 } bb6: { - StorageLive(_6); // bb6[0]: scope 0 at $DIR/match-arm-scopes.rs:15:17: 15:18 - _6 = &(_2.1: bool); // bb6[1]: scope 0 at $DIR/match-arm-scopes.rs:15:17: 15:18 - StorageLive(_8); // bb6[2]: scope 0 at $DIR/match-arm-scopes.rs:15:20: 15:21 - _8 = &(_2.2: std::string::String); // bb6[3]: scope 0 at $DIR/match-arm-scopes.rs:15:20: 15:21 - StorageLive(_9); // bb6[4]: scope 0 at $DIR/match-arm-scopes.rs:15:42: 15:73 - StorageLive(_10); // bb6[5]: scope 0 at $DIR/match-arm-scopes.rs:15:45: 15:49 - _10 = _1; // bb6[6]: scope 0 at $DIR/match-arm-scopes.rs:15:45: 15:49 - switchInt(_10) -> [false: bb7, otherwise: bb8]; // bb6[7]: scope 0 at $DIR/match-arm-scopes.rs:15:42: 15:73 + StorageLive(_6); // bb6[0]: scope 0 at $DIR/match-arm-scopes.rs:16:17: 16:18 + _6 = &(_2.1: bool); // bb6[1]: scope 0 at $DIR/match-arm-scopes.rs:16:17: 16:18 + StorageLive(_8); // bb6[2]: scope 0 at $DIR/match-arm-scopes.rs:16:20: 16:21 + _8 = &(_2.2: std::string::String); // bb6[3]: scope 0 at $DIR/match-arm-scopes.rs:16:20: 16:21 + StorageLive(_9); // bb6[4]: scope 0 at $DIR/match-arm-scopes.rs:16:42: 16:73 + StorageLive(_10); // bb6[5]: scope 0 at $DIR/match-arm-scopes.rs:16:45: 16:49 + _10 = _1; // bb6[6]: scope 0 at $DIR/match-arm-scopes.rs:16:45: 16:49 + switchInt(_10) -> [false: bb7, otherwise: bb8]; // bb6[7]: scope 0 at $DIR/match-arm-scopes.rs:16:42: 16:73 } bb7: { - _9 = (*_6); // bb7[0]: scope 0 at $DIR/match-arm-scopes.rs:15:70: 15:71 - StorageDead(_10); // bb7[1]: scope 0 at $DIR/match-arm-scopes.rs:15:72: 15:73 - switchInt(move _9) -> [false: bb13, otherwise: bb12]; // bb7[2]: scope 0 at $DIR/match-arm-scopes.rs:15:42: 15:73 + _9 = (*_6); // bb7[0]: scope 0 at $DIR/match-arm-scopes.rs:16:70: 16:71 + StorageDead(_10); // bb7[1]: scope 0 at $DIR/match-arm-scopes.rs:16:72: 16:73 + switchInt(move _9) -> [false: bb13, otherwise: bb12]; // bb7[2]: scope 0 at $DIR/match-arm-scopes.rs:16:42: 16:73 } bb8: { - _0 = const 3i32; // bb8[0]: scope 0 at $DIR/match-arm-scopes.rs:15:59: 15:60 + _0 = const 3i32; // bb8[0]: scope 0 at $DIR/match-arm-scopes.rs:16:59: 16:60 // ty::Const // + ty: i32 // + val: Value(Scalar(0x00000003)) // mir::Constant - // + span: $DIR/match-arm-scopes.rs:15:59: 15:60 + // + span: $DIR/match-arm-scopes.rs:16:59: 16:60 // + literal: Const { ty: i32, val: Value(Scalar(0x00000003)) } - StorageDead(_10); // bb8[1]: scope 0 at $DIR/match-arm-scopes.rs:15:72: 15:73 - StorageDead(_9); // bb8[2]: scope 0 at $DIR/match-arm-scopes.rs:15:78: 15:79 - StorageDead(_8); // bb8[3]: scope 0 at $DIR/match-arm-scopes.rs:15:78: 15:79 - StorageDead(_6); // bb8[4]: scope 0 at $DIR/match-arm-scopes.rs:15:78: 15:79 - goto -> bb11; // bb8[5]: scope 0 at $DIR/match-arm-scopes.rs:15:52: 15:60 + StorageDead(_10); // bb8[1]: scope 0 at $DIR/match-arm-scopes.rs:16:72: 16:73 + StorageDead(_9); // bb8[2]: scope 0 at $DIR/match-arm-scopes.rs:16:78: 16:79 + StorageDead(_8); // bb8[3]: scope 0 at $DIR/match-arm-scopes.rs:16:78: 16:79 + StorageDead(_6); // bb8[4]: scope 0 at $DIR/match-arm-scopes.rs:16:78: 16:79 + goto -> bb11; // bb8[5]: scope 0 at $DIR/match-arm-scopes.rs:16:52: 16:60 } bb9: { - return; // bb9[0]: scope 0 at $DIR/match-arm-scopes.rs:18:2: 18:2 + return; // bb9[0]: scope 0 at $DIR/match-arm-scopes.rs:19:2: 19:2 } bb10 (cleanup): { - goto -> bb25; // bb10[0]: scope 0 at $DIR/match-arm-scopes.rs:18:1: 18:2 + goto -> bb25; // bb10[0]: scope 0 at $DIR/match-arm-scopes.rs:19:1: 19:2 } bb11: { - drop(_2) -> [return: bb9, unwind: bb1]; // bb11[0]: scope 0 at $DIR/match-arm-scopes.rs:18:1: 18:2 + drop(_2) -> [return: bb9, unwind: bb1]; // bb11[0]: scope 0 at $DIR/match-arm-scopes.rs:19:1: 19:2 } bb12: { - StorageDead(_9); // bb12[0]: scope 0 at $DIR/match-arm-scopes.rs:15:78: 15:79 - StorageLive(_5); // bb12[1]: scope 0 at $DIR/match-arm-scopes.rs:15:17: 15:18 - _5 = (_2.1: bool); // bb12[2]: scope 0 at $DIR/match-arm-scopes.rs:15:17: 15:18 - StorageLive(_7); // bb12[3]: scope 0 at $DIR/match-arm-scopes.rs:15:20: 15:21 - _7 = move (_2.2: std::string::String); // bb12[4]: scope 0 at $DIR/match-arm-scopes.rs:15:20: 15:21 - goto -> bb5; // bb12[5]: scope 0 at $DIR/match-arm-scopes.rs:14:5: 17:6 + StorageDead(_9); // bb12[0]: scope 0 at $DIR/match-arm-scopes.rs:16:78: 16:79 + StorageLive(_5); // bb12[1]: scope 0 at $DIR/match-arm-scopes.rs:16:17: 16:18 + _5 = (_2.1: bool); // bb12[2]: scope 0 at $DIR/match-arm-scopes.rs:16:17: 16:18 + StorageLive(_7); // bb12[3]: scope 0 at $DIR/match-arm-scopes.rs:16:20: 16:21 + _7 = move (_2.2: std::string::String); // bb12[4]: scope 0 at $DIR/match-arm-scopes.rs:16:20: 16:21 + goto -> bb5; // bb12[5]: scope 0 at $DIR/match-arm-scopes.rs:15:5: 18:6 } bb13: { - StorageDead(_9); // bb13[0]: scope 0 at $DIR/match-arm-scopes.rs:15:78: 15:79 - StorageDead(_8); // bb13[1]: scope 0 at $DIR/match-arm-scopes.rs:15:78: 15:79 - StorageDead(_6); // bb13[2]: scope 0 at $DIR/match-arm-scopes.rs:15:78: 15:79 - goto -> bb2; // bb13[3]: scope 0 at $DIR/match-arm-scopes.rs:15:42: 15:73 + StorageDead(_9); // bb13[0]: scope 0 at $DIR/match-arm-scopes.rs:16:78: 16:79 + StorageDead(_8); // bb13[1]: scope 0 at $DIR/match-arm-scopes.rs:16:78: 16:79 + StorageDead(_6); // bb13[2]: scope 0 at $DIR/match-arm-scopes.rs:16:78: 16:79 + goto -> bb2; // bb13[3]: scope 0 at $DIR/match-arm-scopes.rs:16:42: 16:73 } bb14: { - StorageLive(_6); // bb14[0]: scope 0 at $DIR/match-arm-scopes.rs:15:26: 15:27 - _6 = &(_2.0: bool); // bb14[1]: scope 0 at $DIR/match-arm-scopes.rs:15:26: 15:27 - StorageLive(_8); // bb14[2]: scope 0 at $DIR/match-arm-scopes.rs:15:36: 15:37 - _8 = &(_2.2: std::string::String); // bb14[3]: scope 0 at $DIR/match-arm-scopes.rs:15:36: 15:37 - StorageLive(_12); // bb14[4]: scope 0 at $DIR/match-arm-scopes.rs:15:42: 15:73 - StorageLive(_13); // bb14[5]: scope 0 at $DIR/match-arm-scopes.rs:15:45: 15:49 - _13 = _1; // bb14[6]: scope 0 at $DIR/match-arm-scopes.rs:15:45: 15:49 - switchInt(_13) -> [false: bb15, otherwise: bb16]; // bb14[7]: scope 0 at $DIR/match-arm-scopes.rs:15:42: 15:73 + StorageLive(_6); // bb14[0]: scope 0 at $DIR/match-arm-scopes.rs:16:26: 16:27 + _6 = &(_2.0: bool); // bb14[1]: scope 0 at $DIR/match-arm-scopes.rs:16:26: 16:27 + StorageLive(_8); // bb14[2]: scope 0 at $DIR/match-arm-scopes.rs:16:36: 16:37 + _8 = &(_2.2: std::string::String); // bb14[3]: scope 0 at $DIR/match-arm-scopes.rs:16:36: 16:37 + StorageLive(_12); // bb14[4]: scope 0 at $DIR/match-arm-scopes.rs:16:42: 16:73 + StorageLive(_13); // bb14[5]: scope 0 at $DIR/match-arm-scopes.rs:16:45: 16:49 + _13 = _1; // bb14[6]: scope 0 at $DIR/match-arm-scopes.rs:16:45: 16:49 + switchInt(_13) -> [false: bb15, otherwise: bb16]; // bb14[7]: scope 0 at $DIR/match-arm-scopes.rs:16:42: 16:73 } bb15: { - _12 = (*_6); // bb15[0]: scope 0 at $DIR/match-arm-scopes.rs:15:70: 15:71 - StorageDead(_13); // bb15[1]: scope 0 at $DIR/match-arm-scopes.rs:15:72: 15:73 - switchInt(move _12) -> [false: bb18, otherwise: bb17]; // bb15[2]: scope 0 at $DIR/match-arm-scopes.rs:15:42: 15:73 + _12 = (*_6); // bb15[0]: scope 0 at $DIR/match-arm-scopes.rs:16:70: 16:71 + StorageDead(_13); // bb15[1]: scope 0 at $DIR/match-arm-scopes.rs:16:72: 16:73 + switchInt(move _12) -> [false: bb18, otherwise: bb17]; // bb15[2]: scope 0 at $DIR/match-arm-scopes.rs:16:42: 16:73 } bb16: { - _0 = const 3i32; // bb16[0]: scope 0 at $DIR/match-arm-scopes.rs:15:59: 15:60 + _0 = const 3i32; // bb16[0]: scope 0 at $DIR/match-arm-scopes.rs:16:59: 16:60 // ty::Const // + ty: i32 // + val: Value(Scalar(0x00000003)) // mir::Constant - // + span: $DIR/match-arm-scopes.rs:15:59: 15:60 + // + span: $DIR/match-arm-scopes.rs:16:59: 16:60 // + literal: Const { ty: i32, val: Value(Scalar(0x00000003)) } - StorageDead(_13); // bb16[1]: scope 0 at $DIR/match-arm-scopes.rs:15:72: 15:73 - StorageDead(_12); // bb16[2]: scope 0 at $DIR/match-arm-scopes.rs:15:78: 15:79 - StorageDead(_8); // bb16[3]: scope 0 at $DIR/match-arm-scopes.rs:15:78: 15:79 - StorageDead(_6); // bb16[4]: scope 0 at $DIR/match-arm-scopes.rs:15:78: 15:79 - goto -> bb11; // bb16[5]: scope 0 at $DIR/match-arm-scopes.rs:15:52: 15:60 + StorageDead(_13); // bb16[1]: scope 0 at $DIR/match-arm-scopes.rs:16:72: 16:73 + StorageDead(_12); // bb16[2]: scope 0 at $DIR/match-arm-scopes.rs:16:78: 16:79 + StorageDead(_8); // bb16[3]: scope 0 at $DIR/match-arm-scopes.rs:16:78: 16:79 + StorageDead(_6); // bb16[4]: scope 0 at $DIR/match-arm-scopes.rs:16:78: 16:79 + goto -> bb11; // bb16[5]: scope 0 at $DIR/match-arm-scopes.rs:16:52: 16:60 } bb17: { - StorageDead(_12); // bb17[0]: scope 0 at $DIR/match-arm-scopes.rs:15:78: 15:79 - StorageLive(_5); // bb17[1]: scope 0 at $DIR/match-arm-scopes.rs:15:26: 15:27 - _5 = (_2.0: bool); // bb17[2]: scope 0 at $DIR/match-arm-scopes.rs:15:26: 15:27 - StorageLive(_7); // bb17[3]: scope 0 at $DIR/match-arm-scopes.rs:15:36: 15:37 - _7 = move (_2.2: std::string::String); // bb17[4]: scope 0 at $DIR/match-arm-scopes.rs:15:36: 15:37 - goto -> bb5; // bb17[5]: scope 0 at $DIR/match-arm-scopes.rs:14:5: 17:6 + StorageDead(_12); // bb17[0]: scope 0 at $DIR/match-arm-scopes.rs:16:78: 16:79 + StorageLive(_5); // bb17[1]: scope 0 at $DIR/match-arm-scopes.rs:16:26: 16:27 + _5 = (_2.0: bool); // bb17[2]: scope 0 at $DIR/match-arm-scopes.rs:16:26: 16:27 + StorageLive(_7); // bb17[3]: scope 0 at $DIR/match-arm-scopes.rs:16:36: 16:37 + _7 = move (_2.2: std::string::String); // bb17[4]: scope 0 at $DIR/match-arm-scopes.rs:16:36: 16:37 + goto -> bb5; // bb17[5]: scope 0 at $DIR/match-arm-scopes.rs:15:5: 18:6 } bb18: { - StorageDead(_12); // bb18[0]: scope 0 at $DIR/match-arm-scopes.rs:15:78: 15:79 - StorageDead(_8); // bb18[1]: scope 0 at $DIR/match-arm-scopes.rs:15:78: 15:79 - StorageDead(_6); // bb18[2]: scope 0 at $DIR/match-arm-scopes.rs:15:78: 15:79 - goto -> bb3; // bb18[3]: scope 0 at $DIR/match-arm-scopes.rs:15:42: 15:73 + StorageDead(_12); // bb18[0]: scope 0 at $DIR/match-arm-scopes.rs:16:78: 16:79 + StorageDead(_8); // bb18[1]: scope 0 at $DIR/match-arm-scopes.rs:16:78: 16:79 + StorageDead(_6); // bb18[2]: scope 0 at $DIR/match-arm-scopes.rs:16:78: 16:79 + goto -> bb3; // bb18[3]: scope 0 at $DIR/match-arm-scopes.rs:16:42: 16:73 } bb19: { - StorageDead(_7); // bb19[0]: scope 0 at $DIR/match-arm-scopes.rs:15:78: 15:79 - StorageDead(_5); // bb19[1]: scope 0 at $DIR/match-arm-scopes.rs:15:78: 15:79 - StorageDead(_8); // bb19[2]: scope 0 at $DIR/match-arm-scopes.rs:15:78: 15:79 - StorageDead(_6); // bb19[3]: scope 0 at $DIR/match-arm-scopes.rs:15:78: 15:79 - goto -> bb23; // bb19[4]: scope 0 at $DIR/match-arm-scopes.rs:14:5: 17:6 + StorageDead(_7); // bb19[0]: scope 0 at $DIR/match-arm-scopes.rs:16:78: 16:79 + StorageDead(_5); // bb19[1]: scope 0 at $DIR/match-arm-scopes.rs:16:78: 16:79 + StorageDead(_8); // bb19[2]: scope 0 at $DIR/match-arm-scopes.rs:16:78: 16:79 + StorageDead(_6); // bb19[3]: scope 0 at $DIR/match-arm-scopes.rs:16:78: 16:79 + goto -> bb23; // bb19[4]: scope 0 at $DIR/match-arm-scopes.rs:15:5: 18:6 } bb20: { - _0 = const 2i32; // bb20[0]: scope 2 at $DIR/match-arm-scopes.rs:16:41: 16:42 + _0 = const 2i32; // bb20[0]: scope 2 at $DIR/match-arm-scopes.rs:17:41: 17:42 // ty::Const // + ty: i32 // + val: Value(Scalar(0x00000002)) // mir::Constant - // + span: $DIR/match-arm-scopes.rs:16:41: 16:42 + // + span: $DIR/match-arm-scopes.rs:17:41: 17:42 // + literal: Const { ty: i32, val: Value(Scalar(0x00000002)) } - drop(_16) -> [return: bb22, unwind: bb10]; // bb20[1]: scope 0 at $DIR/match-arm-scopes.rs:16:42: 16:43 + drop(_16) -> [return: bb22, unwind: bb10]; // bb20[1]: scope 0 at $DIR/match-arm-scopes.rs:17:42: 17:43 } bb21: { - StorageLive(_15); // bb21[0]: scope 0 at $DIR/match-arm-scopes.rs:16:16: 16:17 - _15 = (_2.1: bool); // bb21[1]: scope 0 at $DIR/match-arm-scopes.rs:16:16: 16:17 - StorageLive(_16); // bb21[2]: scope 0 at $DIR/match-arm-scopes.rs:16:19: 16:20 - _16 = move (_2.2: std::string::String); // bb21[3]: scope 0 at $DIR/match-arm-scopes.rs:16:19: 16:20 - goto -> bb20; // bb21[4]: scope 0 at $DIR/match-arm-scopes.rs:14:5: 17:6 + StorageLive(_15); // bb21[0]: scope 0 at $DIR/match-arm-scopes.rs:17:16: 17:17 + _15 = (_2.1: bool); // bb21[1]: scope 0 at $DIR/match-arm-scopes.rs:17:16: 17:17 + StorageLive(_16); // bb21[2]: scope 0 at $DIR/match-arm-scopes.rs:17:19: 17:20 + _16 = move (_2.2: std::string::String); // bb21[3]: scope 0 at $DIR/match-arm-scopes.rs:17:19: 17:20 + goto -> bb20; // bb21[4]: scope 0 at $DIR/match-arm-scopes.rs:15:5: 18:6 } bb22: { - StorageDead(_16); // bb22[0]: scope 0 at $DIR/match-arm-scopes.rs:16:42: 16:43 - StorageDead(_15); // bb22[1]: scope 0 at $DIR/match-arm-scopes.rs:16:42: 16:43 - goto -> bb23; // bb22[2]: scope 0 at $DIR/match-arm-scopes.rs:14:5: 17:6 + StorageDead(_16); // bb22[0]: scope 0 at $DIR/match-arm-scopes.rs:17:42: 17:43 + StorageDead(_15); // bb22[1]: scope 0 at $DIR/match-arm-scopes.rs:17:42: 17:43 + goto -> bb23; // bb22[2]: scope 0 at $DIR/match-arm-scopes.rs:15:5: 18:6 } bb23: { - goto -> bb29; // bb23[0]: scope 0 at $DIR/match-arm-scopes.rs:18:1: 18:2 + goto -> bb29; // bb23[0]: scope 0 at $DIR/match-arm-scopes.rs:19:1: 19:2 } bb24 (cleanup): { - goto -> bb1; // bb24[0]: scope 0 at $DIR/match-arm-scopes.rs:18:1: 18:2 + goto -> bb1; // bb24[0]: scope 0 at $DIR/match-arm-scopes.rs:19:1: 19:2 } bb25 (cleanup): { - goto -> bb24; // bb25[0]: scope 0 at $DIR/match-arm-scopes.rs:18:1: 18:2 + goto -> bb24; // bb25[0]: scope 0 at $DIR/match-arm-scopes.rs:19:1: 19:2 } bb26: { - goto -> bb9; // bb26[0]: scope 0 at $DIR/match-arm-scopes.rs:18:1: 18:2 + goto -> bb9; // bb26[0]: scope 0 at $DIR/match-arm-scopes.rs:19:1: 19:2 } bb27 (cleanup): { - goto -> bb1; // bb27[0]: scope 0 at $DIR/match-arm-scopes.rs:18:1: 18:2 + goto -> bb1; // bb27[0]: scope 0 at $DIR/match-arm-scopes.rs:19:1: 19:2 } bb28 (cleanup): { - goto -> bb27; // bb28[0]: scope 0 at $DIR/match-arm-scopes.rs:18:1: 18:2 + goto -> bb27; // bb28[0]: scope 0 at $DIR/match-arm-scopes.rs:19:1: 19:2 } bb29: { - goto -> bb26; // bb29[0]: scope 0 at $DIR/match-arm-scopes.rs:18:1: 18:2 + goto -> bb26; // bb29[0]: scope 0 at $DIR/match-arm-scopes.rs:19:1: 19:2 } } diff --git a/src/test/mir-opt/match-arm-scopes/rustc.complicated_match.SimplifyCfg-initial.after.mir b/src/test/mir-opt/match-arm-scopes/rustc.complicated_match.SimplifyCfg-initial.after.mir index ad42a85317435..80ce94a7f3c61 100644 --- a/src/test/mir-opt/match-arm-scopes/rustc.complicated_match.SimplifyCfg-initial.after.mir +++ b/src/test/mir-opt/match-arm-scopes/rustc.complicated_match.SimplifyCfg-initial.after.mir @@ -1,246 +1,246 @@ // MIR for `complicated_match` after SimplifyCfg-initial fn complicated_match(_1: bool, _2: (bool, bool, std::string::String)) -> i32 { - debug cond => _1; // in scope 0 at $DIR/match-arm-scopes.rs:13:22: 13:26 - debug items => _2; // in scope 0 at $DIR/match-arm-scopes.rs:13:34: 13:39 - let mut _0: i32; // return place in scope 0 at $DIR/match-arm-scopes.rs:13:66: 13:69 - let mut _3: &bool; // in scope 0 at $DIR/match-arm-scopes.rs:14:11: 14:16 - let mut _4: &bool; // in scope 0 at $DIR/match-arm-scopes.rs:14:11: 14:16 - let _5: bool; // in scope 0 at $DIR/match-arm-scopes.rs:15:17: 15:18 - let _6: &bool; // in scope 0 at $DIR/match-arm-scopes.rs:15:17: 15:18 - let _7: std::string::String; // in scope 0 at $DIR/match-arm-scopes.rs:15:20: 15:21 - let _8: &std::string::String; // in scope 0 at $DIR/match-arm-scopes.rs:15:20: 15:21 - let mut _9: bool; // in scope 0 at $DIR/match-arm-scopes.rs:15:42: 15:73 - let mut _10: bool; // in scope 0 at $DIR/match-arm-scopes.rs:15:45: 15:49 - let mut _11: !; // in scope 0 at $DIR/match-arm-scopes.rs:15:52: 15:60 - let mut _12: bool; // in scope 0 at $DIR/match-arm-scopes.rs:15:42: 15:73 - let mut _13: bool; // in scope 0 at $DIR/match-arm-scopes.rs:15:45: 15:49 - let mut _14: !; // in scope 0 at $DIR/match-arm-scopes.rs:15:52: 15:60 - let _15: bool; // in scope 0 at $DIR/match-arm-scopes.rs:16:16: 16:17 - let _16: std::string::String; // in scope 0 at $DIR/match-arm-scopes.rs:16:19: 16:20 + debug cond => _1; // in scope 0 at $DIR/match-arm-scopes.rs:14:22: 14:26 + debug items => _2; // in scope 0 at $DIR/match-arm-scopes.rs:14:34: 14:39 + let mut _0: i32; // return place in scope 0 at $DIR/match-arm-scopes.rs:14:66: 14:69 + let mut _3: &bool; // in scope 0 at $DIR/match-arm-scopes.rs:15:11: 15:16 + let mut _4: &bool; // in scope 0 at $DIR/match-arm-scopes.rs:15:11: 15:16 + let _5: bool; // in scope 0 at $DIR/match-arm-scopes.rs:16:17: 16:18 + let _6: &bool; // in scope 0 at $DIR/match-arm-scopes.rs:16:17: 16:18 + let _7: std::string::String; // in scope 0 at $DIR/match-arm-scopes.rs:16:20: 16:21 + let _8: &std::string::String; // in scope 0 at $DIR/match-arm-scopes.rs:16:20: 16:21 + let mut _9: bool; // in scope 0 at $DIR/match-arm-scopes.rs:16:42: 16:73 + let mut _10: bool; // in scope 0 at $DIR/match-arm-scopes.rs:16:45: 16:49 + let mut _11: !; // in scope 0 at $DIR/match-arm-scopes.rs:16:52: 16:60 + let mut _12: bool; // in scope 0 at $DIR/match-arm-scopes.rs:16:42: 16:73 + let mut _13: bool; // in scope 0 at $DIR/match-arm-scopes.rs:16:45: 16:49 + let mut _14: !; // in scope 0 at $DIR/match-arm-scopes.rs:16:52: 16:60 + let _15: bool; // in scope 0 at $DIR/match-arm-scopes.rs:17:16: 17:17 + let _16: std::string::String; // in scope 0 at $DIR/match-arm-scopes.rs:17:19: 17:20 scope 1 { - debug a => _5; // in scope 1 at $DIR/match-arm-scopes.rs:15:17: 15:18 - debug a => _6; // in scope 1 at $DIR/match-arm-scopes.rs:15:17: 15:18 - debug s => _7; // in scope 1 at $DIR/match-arm-scopes.rs:15:20: 15:21 - debug s => _8; // in scope 1 at $DIR/match-arm-scopes.rs:15:20: 15:21 + debug a => _5; // in scope 1 at $DIR/match-arm-scopes.rs:16:17: 16:18 + debug a => _6; // in scope 1 at $DIR/match-arm-scopes.rs:16:17: 16:18 + debug s => _7; // in scope 1 at $DIR/match-arm-scopes.rs:16:20: 16:21 + debug s => _8; // in scope 1 at $DIR/match-arm-scopes.rs:16:20: 16:21 } scope 2 { - debug b => _15; // in scope 2 at $DIR/match-arm-scopes.rs:16:16: 16:17 - debug t => _16; // in scope 2 at $DIR/match-arm-scopes.rs:16:19: 16:20 + debug b => _15; // in scope 2 at $DIR/match-arm-scopes.rs:17:16: 17:17 + debug t => _16; // in scope 2 at $DIR/match-arm-scopes.rs:17:19: 17:20 } bb0: { - FakeRead(ForMatchedPlace, _2); // bb0[0]: scope 0 at $DIR/match-arm-scopes.rs:14:11: 14:16 - switchInt((_2.0: bool)) -> [false: bb2, otherwise: bb3]; // bb0[1]: scope 0 at $DIR/match-arm-scopes.rs:15:10: 15:15 + FakeRead(ForMatchedPlace, _2); // bb0[0]: scope 0 at $DIR/match-arm-scopes.rs:15:11: 15:16 + switchInt((_2.0: bool)) -> [false: bb2, otherwise: bb3]; // bb0[1]: scope 0 at $DIR/match-arm-scopes.rs:16:10: 16:15 } bb1 (cleanup): { - resume; // bb1[0]: scope 0 at $DIR/match-arm-scopes.rs:13:1: 18:2 + resume; // bb1[0]: scope 0 at $DIR/match-arm-scopes.rs:14:1: 19:2 } bb2: { - falseEdges -> [real: bb9, imaginary: bb4]; // bb2[0]: scope 0 at $DIR/match-arm-scopes.rs:15:9: 15:22 + falseEdges -> [real: bb9, imaginary: bb4]; // bb2[0]: scope 0 at $DIR/match-arm-scopes.rs:16:9: 16:22 } bb3: { - switchInt((_2.1: bool)) -> [false: bb4, otherwise: bb5]; // bb3[0]: scope 0 at $DIR/match-arm-scopes.rs:15:29: 15:34 + switchInt((_2.1: bool)) -> [false: bb4, otherwise: bb5]; // bb3[0]: scope 0 at $DIR/match-arm-scopes.rs:16:29: 16:34 } bb4: { - falseEdges -> [real: bb18, imaginary: bb6]; // bb4[0]: scope 0 at $DIR/match-arm-scopes.rs:15:25: 15:38 + falseEdges -> [real: bb18, imaginary: bb6]; // bb4[0]: scope 0 at $DIR/match-arm-scopes.rs:16:25: 16:38 } bb5: { - switchInt((_2.0: bool)) -> [false: bb7, otherwise: bb6]; // bb5[0]: scope 0 at $DIR/match-arm-scopes.rs:16:10: 16:14 + switchInt((_2.0: bool)) -> [false: bb7, otherwise: bb6]; // bb5[0]: scope 0 at $DIR/match-arm-scopes.rs:17:10: 17:14 } bb6: { - falseEdges -> [real: bb26, imaginary: bb7]; // bb6[0]: scope 0 at $DIR/match-arm-scopes.rs:16:9: 16:21 + falseEdges -> [real: bb26, imaginary: bb7]; // bb6[0]: scope 0 at $DIR/match-arm-scopes.rs:17:9: 17:21 } bb7: { - StorageLive(_15); // bb7[0]: scope 0 at $DIR/match-arm-scopes.rs:16:32: 16:33 - _15 = (_2.1: bool); // bb7[1]: scope 0 at $DIR/match-arm-scopes.rs:16:32: 16:33 - StorageLive(_16); // bb7[2]: scope 0 at $DIR/match-arm-scopes.rs:16:35: 16:36 - _16 = move (_2.2: std::string::String); // bb7[3]: scope 0 at $DIR/match-arm-scopes.rs:16:35: 16:36 - goto -> bb25; // bb7[4]: scope 0 at $DIR/match-arm-scopes.rs:14:5: 17:6 + StorageLive(_15); // bb7[0]: scope 0 at $DIR/match-arm-scopes.rs:17:32: 17:33 + _15 = (_2.1: bool); // bb7[1]: scope 0 at $DIR/match-arm-scopes.rs:17:32: 17:33 + StorageLive(_16); // bb7[2]: scope 0 at $DIR/match-arm-scopes.rs:17:35: 17:36 + _16 = move (_2.2: std::string::String); // bb7[3]: scope 0 at $DIR/match-arm-scopes.rs:17:35: 17:36 + goto -> bb25; // bb7[4]: scope 0 at $DIR/match-arm-scopes.rs:15:5: 18:6 } bb8: { - _0 = const 1i32; // bb8[0]: scope 1 at $DIR/match-arm-scopes.rs:15:77: 15:78 + _0 = const 1i32; // bb8[0]: scope 1 at $DIR/match-arm-scopes.rs:16:77: 16:78 // ty::Const // + ty: i32 // + val: Value(Scalar(0x00000001)) // mir::Constant - // + span: $DIR/match-arm-scopes.rs:15:77: 15:78 + // + span: $DIR/match-arm-scopes.rs:16:77: 16:78 // + literal: Const { ty: i32, val: Value(Scalar(0x00000001)) } - drop(_7) -> [return: bb24, unwind: bb14]; // bb8[1]: scope 0 at $DIR/match-arm-scopes.rs:15:78: 15:79 + drop(_7) -> [return: bb24, unwind: bb14]; // bb8[1]: scope 0 at $DIR/match-arm-scopes.rs:16:78: 16:79 } bb9: { - StorageLive(_6); // bb9[0]: scope 0 at $DIR/match-arm-scopes.rs:15:17: 15:18 - _6 = &(_2.1: bool); // bb9[1]: scope 0 at $DIR/match-arm-scopes.rs:15:17: 15:18 - StorageLive(_8); // bb9[2]: scope 0 at $DIR/match-arm-scopes.rs:15:20: 15:21 - _8 = &(_2.2: std::string::String); // bb9[3]: scope 0 at $DIR/match-arm-scopes.rs:15:20: 15:21 - _3 = &shallow (_2.0: bool); // bb9[4]: scope 0 at $DIR/match-arm-scopes.rs:14:11: 14:16 - _4 = &shallow (_2.1: bool); // bb9[5]: scope 0 at $DIR/match-arm-scopes.rs:14:11: 14:16 - StorageLive(_9); // bb9[6]: scope 0 at $DIR/match-arm-scopes.rs:15:42: 15:73 - StorageLive(_10); // bb9[7]: scope 0 at $DIR/match-arm-scopes.rs:15:45: 15:49 - _10 = _1; // bb9[8]: scope 0 at $DIR/match-arm-scopes.rs:15:45: 15:49 - FakeRead(ForMatchedPlace, _10); // bb9[9]: scope 0 at $DIR/match-arm-scopes.rs:15:45: 15:49 - switchInt(_10) -> [false: bb11, otherwise: bb10]; // bb9[10]: scope 0 at $DIR/match-arm-scopes.rs:15:42: 15:73 + StorageLive(_6); // bb9[0]: scope 0 at $DIR/match-arm-scopes.rs:16:17: 16:18 + _6 = &(_2.1: bool); // bb9[1]: scope 0 at $DIR/match-arm-scopes.rs:16:17: 16:18 + StorageLive(_8); // bb9[2]: scope 0 at $DIR/match-arm-scopes.rs:16:20: 16:21 + _8 = &(_2.2: std::string::String); // bb9[3]: scope 0 at $DIR/match-arm-scopes.rs:16:20: 16:21 + _3 = &shallow (_2.0: bool); // bb9[4]: scope 0 at $DIR/match-arm-scopes.rs:15:11: 15:16 + _4 = &shallow (_2.1: bool); // bb9[5]: scope 0 at $DIR/match-arm-scopes.rs:15:11: 15:16 + StorageLive(_9); // bb9[6]: scope 0 at $DIR/match-arm-scopes.rs:16:42: 16:73 + StorageLive(_10); // bb9[7]: scope 0 at $DIR/match-arm-scopes.rs:16:45: 16:49 + _10 = _1; // bb9[8]: scope 0 at $DIR/match-arm-scopes.rs:16:45: 16:49 + FakeRead(ForMatchedPlace, _10); // bb9[9]: scope 0 at $DIR/match-arm-scopes.rs:16:45: 16:49 + switchInt(_10) -> [false: bb11, otherwise: bb10]; // bb9[10]: scope 0 at $DIR/match-arm-scopes.rs:16:42: 16:73 } bb10: { - falseEdges -> [real: bb12, imaginary: bb11]; // bb10[0]: scope 0 at $DIR/match-arm-scopes.rs:15:42: 15:73 + falseEdges -> [real: bb12, imaginary: bb11]; // bb10[0]: scope 0 at $DIR/match-arm-scopes.rs:16:42: 16:73 } bb11: { - _9 = (*_6); // bb11[0]: scope 0 at $DIR/match-arm-scopes.rs:15:70: 15:71 - StorageDead(_10); // bb11[1]: scope 0 at $DIR/match-arm-scopes.rs:15:72: 15:73 - switchInt(move _9) -> [false: bb17, otherwise: bb16]; // bb11[2]: scope 0 at $DIR/match-arm-scopes.rs:15:42: 15:73 + _9 = (*_6); // bb11[0]: scope 0 at $DIR/match-arm-scopes.rs:16:70: 16:71 + StorageDead(_10); // bb11[1]: scope 0 at $DIR/match-arm-scopes.rs:16:72: 16:73 + switchInt(move _9) -> [false: bb17, otherwise: bb16]; // bb11[2]: scope 0 at $DIR/match-arm-scopes.rs:16:42: 16:73 } bb12: { - _0 = const 3i32; // bb12[0]: scope 0 at $DIR/match-arm-scopes.rs:15:59: 15:60 + _0 = const 3i32; // bb12[0]: scope 0 at $DIR/match-arm-scopes.rs:16:59: 16:60 // ty::Const // + ty: i32 // + val: Value(Scalar(0x00000003)) // mir::Constant - // + span: $DIR/match-arm-scopes.rs:15:59: 15:60 + // + span: $DIR/match-arm-scopes.rs:16:59: 16:60 // + literal: Const { ty: i32, val: Value(Scalar(0x00000003)) } - StorageDead(_10); // bb12[1]: scope 0 at $DIR/match-arm-scopes.rs:15:72: 15:73 - StorageDead(_9); // bb12[2]: scope 0 at $DIR/match-arm-scopes.rs:15:78: 15:79 - StorageDead(_8); // bb12[3]: scope 0 at $DIR/match-arm-scopes.rs:15:78: 15:79 - StorageDead(_6); // bb12[4]: scope 0 at $DIR/match-arm-scopes.rs:15:78: 15:79 - goto -> bb15; // bb12[5]: scope 0 at $DIR/match-arm-scopes.rs:15:52: 15:60 + StorageDead(_10); // bb12[1]: scope 0 at $DIR/match-arm-scopes.rs:16:72: 16:73 + StorageDead(_9); // bb12[2]: scope 0 at $DIR/match-arm-scopes.rs:16:78: 16:79 + StorageDead(_8); // bb12[3]: scope 0 at $DIR/match-arm-scopes.rs:16:78: 16:79 + StorageDead(_6); // bb12[4]: scope 0 at $DIR/match-arm-scopes.rs:16:78: 16:79 + goto -> bb15; // bb12[5]: scope 0 at $DIR/match-arm-scopes.rs:16:52: 16:60 } bb13: { - return; // bb13[0]: scope 0 at $DIR/match-arm-scopes.rs:18:2: 18:2 + return; // bb13[0]: scope 0 at $DIR/match-arm-scopes.rs:19:2: 19:2 } bb14 (cleanup): { - drop(_2) -> bb1; // bb14[0]: scope 0 at $DIR/match-arm-scopes.rs:18:1: 18:2 + drop(_2) -> bb1; // bb14[0]: scope 0 at $DIR/match-arm-scopes.rs:19:1: 19:2 } bb15: { - drop(_2) -> [return: bb13, unwind: bb1]; // bb15[0]: scope 0 at $DIR/match-arm-scopes.rs:18:1: 18:2 + drop(_2) -> [return: bb13, unwind: bb1]; // bb15[0]: scope 0 at $DIR/match-arm-scopes.rs:19:1: 19:2 } bb16: { - StorageDead(_9); // bb16[0]: scope 0 at $DIR/match-arm-scopes.rs:15:78: 15:79 - FakeRead(ForMatchGuard, _3); // bb16[1]: scope 0 at $DIR/match-arm-scopes.rs:15:72: 15:73 - FakeRead(ForMatchGuard, _4); // bb16[2]: scope 0 at $DIR/match-arm-scopes.rs:15:72: 15:73 - FakeRead(ForGuardBinding, _6); // bb16[3]: scope 0 at $DIR/match-arm-scopes.rs:15:72: 15:73 - FakeRead(ForGuardBinding, _8); // bb16[4]: scope 0 at $DIR/match-arm-scopes.rs:15:72: 15:73 - StorageLive(_5); // bb16[5]: scope 0 at $DIR/match-arm-scopes.rs:15:17: 15:18 - _5 = (_2.1: bool); // bb16[6]: scope 0 at $DIR/match-arm-scopes.rs:15:17: 15:18 - StorageLive(_7); // bb16[7]: scope 0 at $DIR/match-arm-scopes.rs:15:20: 15:21 - _7 = move (_2.2: std::string::String); // bb16[8]: scope 0 at $DIR/match-arm-scopes.rs:15:20: 15:21 - goto -> bb8; // bb16[9]: scope 0 at $DIR/match-arm-scopes.rs:14:5: 17:6 + StorageDead(_9); // bb16[0]: scope 0 at $DIR/match-arm-scopes.rs:16:78: 16:79 + FakeRead(ForMatchGuard, _3); // bb16[1]: scope 0 at $DIR/match-arm-scopes.rs:16:72: 16:73 + FakeRead(ForMatchGuard, _4); // bb16[2]: scope 0 at $DIR/match-arm-scopes.rs:16:72: 16:73 + FakeRead(ForGuardBinding, _6); // bb16[3]: scope 0 at $DIR/match-arm-scopes.rs:16:72: 16:73 + FakeRead(ForGuardBinding, _8); // bb16[4]: scope 0 at $DIR/match-arm-scopes.rs:16:72: 16:73 + StorageLive(_5); // bb16[5]: scope 0 at $DIR/match-arm-scopes.rs:16:17: 16:18 + _5 = (_2.1: bool); // bb16[6]: scope 0 at $DIR/match-arm-scopes.rs:16:17: 16:18 + StorageLive(_7); // bb16[7]: scope 0 at $DIR/match-arm-scopes.rs:16:20: 16:21 + _7 = move (_2.2: std::string::String); // bb16[8]: scope 0 at $DIR/match-arm-scopes.rs:16:20: 16:21 + goto -> bb8; // bb16[9]: scope 0 at $DIR/match-arm-scopes.rs:15:5: 18:6 } bb17: { - StorageDead(_9); // bb17[0]: scope 0 at $DIR/match-arm-scopes.rs:15:78: 15:79 - StorageDead(_8); // bb17[1]: scope 0 at $DIR/match-arm-scopes.rs:15:78: 15:79 - StorageDead(_6); // bb17[2]: scope 0 at $DIR/match-arm-scopes.rs:15:78: 15:79 - falseEdges -> [real: bb3, imaginary: bb4]; // bb17[3]: scope 0 at $DIR/match-arm-scopes.rs:15:42: 15:73 + StorageDead(_9); // bb17[0]: scope 0 at $DIR/match-arm-scopes.rs:16:78: 16:79 + StorageDead(_8); // bb17[1]: scope 0 at $DIR/match-arm-scopes.rs:16:78: 16:79 + StorageDead(_6); // bb17[2]: scope 0 at $DIR/match-arm-scopes.rs:16:78: 16:79 + falseEdges -> [real: bb3, imaginary: bb4]; // bb17[3]: scope 0 at $DIR/match-arm-scopes.rs:16:42: 16:73 } bb18: { - StorageLive(_6); // bb18[0]: scope 0 at $DIR/match-arm-scopes.rs:15:26: 15:27 - _6 = &(_2.0: bool); // bb18[1]: scope 0 at $DIR/match-arm-scopes.rs:15:26: 15:27 - StorageLive(_8); // bb18[2]: scope 0 at $DIR/match-arm-scopes.rs:15:36: 15:37 - _8 = &(_2.2: std::string::String); // bb18[3]: scope 0 at $DIR/match-arm-scopes.rs:15:36: 15:37 - _3 = &shallow (_2.0: bool); // bb18[4]: scope 0 at $DIR/match-arm-scopes.rs:14:11: 14:16 - _4 = &shallow (_2.1: bool); // bb18[5]: scope 0 at $DIR/match-arm-scopes.rs:14:11: 14:16 - StorageLive(_12); // bb18[6]: scope 0 at $DIR/match-arm-scopes.rs:15:42: 15:73 - StorageLive(_13); // bb18[7]: scope 0 at $DIR/match-arm-scopes.rs:15:45: 15:49 - _13 = _1; // bb18[8]: scope 0 at $DIR/match-arm-scopes.rs:15:45: 15:49 - FakeRead(ForMatchedPlace, _13); // bb18[9]: scope 0 at $DIR/match-arm-scopes.rs:15:45: 15:49 - switchInt(_13) -> [false: bb20, otherwise: bb19]; // bb18[10]: scope 0 at $DIR/match-arm-scopes.rs:15:42: 15:73 + StorageLive(_6); // bb18[0]: scope 0 at $DIR/match-arm-scopes.rs:16:26: 16:27 + _6 = &(_2.0: bool); // bb18[1]: scope 0 at $DIR/match-arm-scopes.rs:16:26: 16:27 + StorageLive(_8); // bb18[2]: scope 0 at $DIR/match-arm-scopes.rs:16:36: 16:37 + _8 = &(_2.2: std::string::String); // bb18[3]: scope 0 at $DIR/match-arm-scopes.rs:16:36: 16:37 + _3 = &shallow (_2.0: bool); // bb18[4]: scope 0 at $DIR/match-arm-scopes.rs:15:11: 15:16 + _4 = &shallow (_2.1: bool); // bb18[5]: scope 0 at $DIR/match-arm-scopes.rs:15:11: 15:16 + StorageLive(_12); // bb18[6]: scope 0 at $DIR/match-arm-scopes.rs:16:42: 16:73 + StorageLive(_13); // bb18[7]: scope 0 at $DIR/match-arm-scopes.rs:16:45: 16:49 + _13 = _1; // bb18[8]: scope 0 at $DIR/match-arm-scopes.rs:16:45: 16:49 + FakeRead(ForMatchedPlace, _13); // bb18[9]: scope 0 at $DIR/match-arm-scopes.rs:16:45: 16:49 + switchInt(_13) -> [false: bb20, otherwise: bb19]; // bb18[10]: scope 0 at $DIR/match-arm-scopes.rs:16:42: 16:73 } bb19: { - falseEdges -> [real: bb21, imaginary: bb20]; // bb19[0]: scope 0 at $DIR/match-arm-scopes.rs:15:42: 15:73 + falseEdges -> [real: bb21, imaginary: bb20]; // bb19[0]: scope 0 at $DIR/match-arm-scopes.rs:16:42: 16:73 } bb20: { - _12 = (*_6); // bb20[0]: scope 0 at $DIR/match-arm-scopes.rs:15:70: 15:71 - StorageDead(_13); // bb20[1]: scope 0 at $DIR/match-arm-scopes.rs:15:72: 15:73 - switchInt(move _12) -> [false: bb23, otherwise: bb22]; // bb20[2]: scope 0 at $DIR/match-arm-scopes.rs:15:42: 15:73 + _12 = (*_6); // bb20[0]: scope 0 at $DIR/match-arm-scopes.rs:16:70: 16:71 + StorageDead(_13); // bb20[1]: scope 0 at $DIR/match-arm-scopes.rs:16:72: 16:73 + switchInt(move _12) -> [false: bb23, otherwise: bb22]; // bb20[2]: scope 0 at $DIR/match-arm-scopes.rs:16:42: 16:73 } bb21: { - _0 = const 3i32; // bb21[0]: scope 0 at $DIR/match-arm-scopes.rs:15:59: 15:60 + _0 = const 3i32; // bb21[0]: scope 0 at $DIR/match-arm-scopes.rs:16:59: 16:60 // ty::Const // + ty: i32 // + val: Value(Scalar(0x00000003)) // mir::Constant - // + span: $DIR/match-arm-scopes.rs:15:59: 15:60 + // + span: $DIR/match-arm-scopes.rs:16:59: 16:60 // + literal: Const { ty: i32, val: Value(Scalar(0x00000003)) } - StorageDead(_13); // bb21[1]: scope 0 at $DIR/match-arm-scopes.rs:15:72: 15:73 - StorageDead(_12); // bb21[2]: scope 0 at $DIR/match-arm-scopes.rs:15:78: 15:79 - StorageDead(_8); // bb21[3]: scope 0 at $DIR/match-arm-scopes.rs:15:78: 15:79 - StorageDead(_6); // bb21[4]: scope 0 at $DIR/match-arm-scopes.rs:15:78: 15:79 - goto -> bb15; // bb21[5]: scope 0 at $DIR/match-arm-scopes.rs:15:52: 15:60 + StorageDead(_13); // bb21[1]: scope 0 at $DIR/match-arm-scopes.rs:16:72: 16:73 + StorageDead(_12); // bb21[2]: scope 0 at $DIR/match-arm-scopes.rs:16:78: 16:79 + StorageDead(_8); // bb21[3]: scope 0 at $DIR/match-arm-scopes.rs:16:78: 16:79 + StorageDead(_6); // bb21[4]: scope 0 at $DIR/match-arm-scopes.rs:16:78: 16:79 + goto -> bb15; // bb21[5]: scope 0 at $DIR/match-arm-scopes.rs:16:52: 16:60 } bb22: { - StorageDead(_12); // bb22[0]: scope 0 at $DIR/match-arm-scopes.rs:15:78: 15:79 - FakeRead(ForMatchGuard, _3); // bb22[1]: scope 0 at $DIR/match-arm-scopes.rs:15:72: 15:73 - FakeRead(ForMatchGuard, _4); // bb22[2]: scope 0 at $DIR/match-arm-scopes.rs:15:72: 15:73 - FakeRead(ForGuardBinding, _6); // bb22[3]: scope 0 at $DIR/match-arm-scopes.rs:15:72: 15:73 - FakeRead(ForGuardBinding, _8); // bb22[4]: scope 0 at $DIR/match-arm-scopes.rs:15:72: 15:73 - StorageLive(_5); // bb22[5]: scope 0 at $DIR/match-arm-scopes.rs:15:26: 15:27 - _5 = (_2.0: bool); // bb22[6]: scope 0 at $DIR/match-arm-scopes.rs:15:26: 15:27 - StorageLive(_7); // bb22[7]: scope 0 at $DIR/match-arm-scopes.rs:15:36: 15:37 - _7 = move (_2.2: std::string::String); // bb22[8]: scope 0 at $DIR/match-arm-scopes.rs:15:36: 15:37 - goto -> bb8; // bb22[9]: scope 0 at $DIR/match-arm-scopes.rs:14:5: 17:6 + StorageDead(_12); // bb22[0]: scope 0 at $DIR/match-arm-scopes.rs:16:78: 16:79 + FakeRead(ForMatchGuard, _3); // bb22[1]: scope 0 at $DIR/match-arm-scopes.rs:16:72: 16:73 + FakeRead(ForMatchGuard, _4); // bb22[2]: scope 0 at $DIR/match-arm-scopes.rs:16:72: 16:73 + FakeRead(ForGuardBinding, _6); // bb22[3]: scope 0 at $DIR/match-arm-scopes.rs:16:72: 16:73 + FakeRead(ForGuardBinding, _8); // bb22[4]: scope 0 at $DIR/match-arm-scopes.rs:16:72: 16:73 + StorageLive(_5); // bb22[5]: scope 0 at $DIR/match-arm-scopes.rs:16:26: 16:27 + _5 = (_2.0: bool); // bb22[6]: scope 0 at $DIR/match-arm-scopes.rs:16:26: 16:27 + StorageLive(_7); // bb22[7]: scope 0 at $DIR/match-arm-scopes.rs:16:36: 16:37 + _7 = move (_2.2: std::string::String); // bb22[8]: scope 0 at $DIR/match-arm-scopes.rs:16:36: 16:37 + goto -> bb8; // bb22[9]: scope 0 at $DIR/match-arm-scopes.rs:15:5: 18:6 } bb23: { - StorageDead(_12); // bb23[0]: scope 0 at $DIR/match-arm-scopes.rs:15:78: 15:79 - StorageDead(_8); // bb23[1]: scope 0 at $DIR/match-arm-scopes.rs:15:78: 15:79 - StorageDead(_6); // bb23[2]: scope 0 at $DIR/match-arm-scopes.rs:15:78: 15:79 - falseEdges -> [real: bb5, imaginary: bb6]; // bb23[3]: scope 0 at $DIR/match-arm-scopes.rs:15:42: 15:73 + StorageDead(_12); // bb23[0]: scope 0 at $DIR/match-arm-scopes.rs:16:78: 16:79 + StorageDead(_8); // bb23[1]: scope 0 at $DIR/match-arm-scopes.rs:16:78: 16:79 + StorageDead(_6); // bb23[2]: scope 0 at $DIR/match-arm-scopes.rs:16:78: 16:79 + falseEdges -> [real: bb5, imaginary: bb6]; // bb23[3]: scope 0 at $DIR/match-arm-scopes.rs:16:42: 16:73 } bb24: { - StorageDead(_7); // bb24[0]: scope 0 at $DIR/match-arm-scopes.rs:15:78: 15:79 - StorageDead(_5); // bb24[1]: scope 0 at $DIR/match-arm-scopes.rs:15:78: 15:79 - StorageDead(_8); // bb24[2]: scope 0 at $DIR/match-arm-scopes.rs:15:78: 15:79 - StorageDead(_6); // bb24[3]: scope 0 at $DIR/match-arm-scopes.rs:15:78: 15:79 - goto -> bb28; // bb24[4]: scope 0 at $DIR/match-arm-scopes.rs:14:5: 17:6 + StorageDead(_7); // bb24[0]: scope 0 at $DIR/match-arm-scopes.rs:16:78: 16:79 + StorageDead(_5); // bb24[1]: scope 0 at $DIR/match-arm-scopes.rs:16:78: 16:79 + StorageDead(_8); // bb24[2]: scope 0 at $DIR/match-arm-scopes.rs:16:78: 16:79 + StorageDead(_6); // bb24[3]: scope 0 at $DIR/match-arm-scopes.rs:16:78: 16:79 + goto -> bb28; // bb24[4]: scope 0 at $DIR/match-arm-scopes.rs:15:5: 18:6 } bb25: { - _0 = const 2i32; // bb25[0]: scope 2 at $DIR/match-arm-scopes.rs:16:41: 16:42 + _0 = const 2i32; // bb25[0]: scope 2 at $DIR/match-arm-scopes.rs:17:41: 17:42 // ty::Const // + ty: i32 // + val: Value(Scalar(0x00000002)) // mir::Constant - // + span: $DIR/match-arm-scopes.rs:16:41: 16:42 + // + span: $DIR/match-arm-scopes.rs:17:41: 17:42 // + literal: Const { ty: i32, val: Value(Scalar(0x00000002)) } - drop(_16) -> [return: bb27, unwind: bb14]; // bb25[1]: scope 0 at $DIR/match-arm-scopes.rs:16:42: 16:43 + drop(_16) -> [return: bb27, unwind: bb14]; // bb25[1]: scope 0 at $DIR/match-arm-scopes.rs:17:42: 17:43 } bb26: { - StorageLive(_15); // bb26[0]: scope 0 at $DIR/match-arm-scopes.rs:16:16: 16:17 - _15 = (_2.1: bool); // bb26[1]: scope 0 at $DIR/match-arm-scopes.rs:16:16: 16:17 - StorageLive(_16); // bb26[2]: scope 0 at $DIR/match-arm-scopes.rs:16:19: 16:20 - _16 = move (_2.2: std::string::String); // bb26[3]: scope 0 at $DIR/match-arm-scopes.rs:16:19: 16:20 - goto -> bb25; // bb26[4]: scope 0 at $DIR/match-arm-scopes.rs:14:5: 17:6 + StorageLive(_15); // bb26[0]: scope 0 at $DIR/match-arm-scopes.rs:17:16: 17:17 + _15 = (_2.1: bool); // bb26[1]: scope 0 at $DIR/match-arm-scopes.rs:17:16: 17:17 + StorageLive(_16); // bb26[2]: scope 0 at $DIR/match-arm-scopes.rs:17:19: 17:20 + _16 = move (_2.2: std::string::String); // bb26[3]: scope 0 at $DIR/match-arm-scopes.rs:17:19: 17:20 + goto -> bb25; // bb26[4]: scope 0 at $DIR/match-arm-scopes.rs:15:5: 18:6 } bb27: { - StorageDead(_16); // bb27[0]: scope 0 at $DIR/match-arm-scopes.rs:16:42: 16:43 - StorageDead(_15); // bb27[1]: scope 0 at $DIR/match-arm-scopes.rs:16:42: 16:43 - goto -> bb28; // bb27[2]: scope 0 at $DIR/match-arm-scopes.rs:14:5: 17:6 + StorageDead(_16); // bb27[0]: scope 0 at $DIR/match-arm-scopes.rs:17:42: 17:43 + StorageDead(_15); // bb27[1]: scope 0 at $DIR/match-arm-scopes.rs:17:42: 17:43 + goto -> bb28; // bb27[2]: scope 0 at $DIR/match-arm-scopes.rs:15:5: 18:6 } bb28: { - drop(_2) -> [return: bb13, unwind: bb1]; // bb28[0]: scope 0 at $DIR/match-arm-scopes.rs:18:1: 18:2 + drop(_2) -> [return: bb13, unwind: bb1]; // bb28[0]: scope 0 at $DIR/match-arm-scopes.rs:19:1: 19:2 } }