1- // MIR for `main` before PromoteTemps
1+ // MIR for `main` after built
22
33fn main() -> () {
44 let mut _0 : (); // return place in scope 0 at $DIR/match_false_edges.rs:+0:11: +0:11
@@ -43,41 +43,54 @@ fn main() -> () {
4343 }
4444
4545 bb1 : {
46- falseEdge -> [real : bb9 , imaginary: bb4 ]; // scope 0 at $DIR/match_false_edges.rs:+3:9: +3:11
46+ falseEdge -> [real : bb13 , imaginary: bb6 ]; // scope 0 at $DIR/match_false_edges.rs:+3:9: +3:11
4747 }
4848
4949 bb2 : {
50- falseEdge -> [real : bb5 , imaginary: bb1]; // scope 0 at $DIR/match_false_edges.rs:+2:9: +2:17
50+ falseEdge -> [real : bb8 , imaginary: bb1]; // scope 0 at $DIR/match_false_edges.rs:+2:9: +2:17
5151 }
5252
5353 bb3 : {
54+ goto -> bb1; // scope 0 at $DIR/match_false_edges.rs:+1:13 : +1:26
55+ }
56+
57+ bb4 : {
58+ _3 = discriminant(_2); // scope 0 at $DIR/match_false_edges.rs:+1:19 : +1:26
59+ switchInt(move _3) -> [1_isize : bb6, otherwise: bb5]; // scope 0 at $DIR/match_false_edges.rs:+1:13: +1:26
60+ }
61+
62+ bb5 : {
5463 StorageLive(_14); // scope 0 at $DIR/match_false_edges.rs:+5:9 : +5:11
5564 _14 = _2; // scope 0 at $DIR/match_false_edges.rs:+5:9 : +5:11
5665 _1 = const 4_i32; // scope 5 at $DIR/match_false_edges.rs:+5:15 : +5:16
5766 StorageDead(_14); // scope 0 at $DIR/match_false_edges.rs:+5:15 : +5:16
58- goto -> bb14 ; // scope 0 at $DIR/match_false_edges.rs:+5:15 : +5:16
67+ goto -> bb19 ; // scope 0 at $DIR/match_false_edges.rs:+5:15 : +5:16
5968 }
6069
61- bb4 : {
62- falseEdge -> [real : bb10 , imaginary: bb3 ]; // scope 0 at $DIR/match_false_edges.rs:+4:9: +4:16
70+ bb6 : {
71+ falseEdge -> [real : bb14 , imaginary: bb5 ]; // scope 0 at $DIR/match_false_edges.rs:+4:9: +4:16
6372 }
6473
65- bb5 : {
74+ bb7 : {
75+ goto -> bb5; // scope 0 at $DIR/match_false_edges.rs:+1:13 : +1:26
76+ }
77+
78+ bb8 : {
6679 StorageLive(_7); // scope 0 at $DIR/match_false_edges.rs:+2:14 : +2:16
6780 _7 = &((_2 as Some).0 : i32); // scope 0 at $DIR/match_false_edges.rs:+2:14: +2:16
6881 _5 = &shallow _2; // scope 0 at $DIR/match_false_edges.rs:+1:19 : +1:26
6982 StorageLive(_8); // scope 0 at $DIR/match_false_edges.rs:+2:21 : +2:28
70- _8 = guard() -> [return : bb6 , unwind: bb15 ]; // scope 0 at $DIR/match_false_edges.rs:+2:21: +2:28
83+ _8 = guard() -> [return : bb9 , unwind: bb20 ]; // scope 0 at $DIR/match_false_edges.rs:+2:21: +2:28
7184 // mir::Constant
7285 // + span : $DIR/match_false_edges.rs:34:21: 34:26
7386 // + literal : Const { ty: fn() -> bool {guard}, val: Value(<ZST>) }
7487 }
7588
76- bb6 : {
77- switchInt(move _8) -> [false : bb8 , otherwise: bb7 ]; // scope 0 at $DIR/match_false_edges.rs:+2:21: +2:28
89+ bb9 : {
90+ switchInt(move _8) -> [false : bb11 , otherwise: bb10 ]; // scope 0 at $DIR/match_false_edges.rs:+2:21: +2:28
7891 }
7992
80- bb7 : {
93+ bb10 : {
8194 StorageDead(_8); // scope 0 at $DIR/match_false_edges.rs:+2:27 : +2:28
8295 FakeRead(ForMatchGuard, _5); // scope 0 at $DIR/match_false_edges.rs:+2:27 : +2:28
8396 FakeRead(ForGuardBinding, _7); // scope 0 at $DIR/match_false_edges.rs:+2:27 : +2:28
@@ -86,41 +99,45 @@ fn main() -> () {
8699 _1 = const 1_i32; // scope 2 at $DIR/match_false_edges.rs:+2:32 : +2:33
87100 StorageDead(_6); // scope 0 at $DIR/match_false_edges.rs:+2:32 : +2:33
88101 StorageDead(_7); // scope 0 at $DIR/match_false_edges.rs:+2:32 : +2:33
89- goto -> bb14 ; // scope 0 at $DIR/match_false_edges.rs:+2:32 : +2:33
102+ goto -> bb19 ; // scope 0 at $DIR/match_false_edges.rs:+2:32 : +2:33
90103 }
91104
92- bb8 : {
105+ bb11 : {
106+ goto -> bb12; // scope 0 at $DIR/match_false_edges.rs:+2:21 : +2:28
107+ }
108+
109+ bb12 : {
93110 StorageDead(_8); // scope 0 at $DIR/match_false_edges.rs:+2:27 : +2:28
94111 StorageDead(_7); // scope 0 at $DIR/match_false_edges.rs:+2:32 : +2:33
95- falseEdge -> [real : bb1 , imaginary: bb1]; // scope 0 at $DIR/match_false_edges.rs:+2:21: +2:28
112+ falseEdge -> [real : bb3 , imaginary: bb1]; // scope 0 at $DIR/match_false_edges.rs:+2:21: +2:28
96113 }
97114
98- bb9 : {
115+ bb13 : {
99116 StorageLive(_9); // scope 0 at $DIR/match_false_edges.rs:+3:9 : +3:11
100117 _9 = _2; // scope 0 at $DIR/match_false_edges.rs:+3:9 : +3:11
101118 _1 = const 2_i32; // scope 3 at $DIR/match_false_edges.rs:+3:15 : +3:16
102119 StorageDead(_9); // scope 0 at $DIR/match_false_edges.rs:+3:15 : +3:16
103- goto -> bb14 ; // scope 0 at $DIR/match_false_edges.rs:+3:15 : +3:16
120+ goto -> bb19 ; // scope 0 at $DIR/match_false_edges.rs:+3:15 : +3:16
104121 }
105122
106- bb10 : {
123+ bb14 : {
107124 StorageLive(_11); // scope 0 at $DIR/match_false_edges.rs:+4:14 : +4:15
108125 _11 = &((_2 as Some).0 : i32); // scope 0 at $DIR/match_false_edges.rs:+4:14: +4:15
109126 _5 = &shallow _2; // scope 0 at $DIR/match_false_edges.rs:+1:19 : +1:26
110127 StorageLive(_12); // scope 0 at $DIR/match_false_edges.rs:+4:20 : +4:29
111128 StorageLive(_13); // scope 0 at $DIR/match_false_edges.rs:+4:27 : +4:28
112129 _13 = (*_11); // scope 0 at $DIR/match_false_edges.rs:+4:27 : +4:28
113- _12 = guard2(move _13) -> [return : bb11 , unwind: bb15 ]; // scope 0 at $DIR/match_false_edges.rs:+4:20: +4:29
130+ _12 = guard2(move _13) -> [return : bb15 , unwind: bb20 ]; // scope 0 at $DIR/match_false_edges.rs:+4:20: +4:29
114131 // mir::Constant
115132 // + span : $DIR/match_false_edges.rs:36:20: 36:26
116133 // + literal : Const { ty: fn(i32) -> bool {guard2}, val: Value(<ZST>) }
117134 }
118135
119- bb11 : {
120- switchInt(move _12) -> [false : bb13 , otherwise: bb12 ]; // scope 0 at $DIR/match_false_edges.rs:+4:20: +4:29
136+ bb15 : {
137+ switchInt(move _12) -> [false : bb17 , otherwise: bb16 ]; // scope 0 at $DIR/match_false_edges.rs:+4:20: +4:29
121138 }
122139
123- bb12 : {
140+ bb16 : {
124141 StorageDead(_13); // scope 0 at $DIR/match_false_edges.rs:+4:28 : +4:29
125142 StorageDead(_12); // scope 0 at $DIR/match_false_edges.rs:+4:28 : +4:29
126143 FakeRead(ForMatchGuard, _5); // scope 0 at $DIR/match_false_edges.rs:+4:28 : +4:29
@@ -130,24 +147,28 @@ fn main() -> () {
130147 _1 = const 3_i32; // scope 4 at $DIR/match_false_edges.rs:+4:33 : +4:34
131148 StorageDead(_10); // scope 0 at $DIR/match_false_edges.rs:+4:33 : +4:34
132149 StorageDead(_11); // scope 0 at $DIR/match_false_edges.rs:+4:33 : +4:34
133- goto -> bb14 ; // scope 0 at $DIR/match_false_edges.rs:+4:33 : +4:34
150+ goto -> bb19 ; // scope 0 at $DIR/match_false_edges.rs:+4:33 : +4:34
134151 }
135152
136- bb13 : {
153+ bb17 : {
154+ goto -> bb18; // scope 0 at $DIR/match_false_edges.rs:+4:20 : +4:29
155+ }
156+
157+ bb18 : {
137158 StorageDead(_13); // scope 0 at $DIR/match_false_edges.rs:+4:28 : +4:29
138159 StorageDead(_12); // scope 0 at $DIR/match_false_edges.rs:+4:28 : +4:29
139160 StorageDead(_11); // scope 0 at $DIR/match_false_edges.rs:+4:33 : +4:34
140- falseEdge -> [real : bb3 , imaginary: bb3 ]; // scope 0 at $DIR/match_false_edges.rs:+4:20: +4:29
161+ falseEdge -> [real : bb7 , imaginary: bb5 ]; // scope 0 at $DIR/match_false_edges.rs:+4:20: +4:29
141162 }
142163
143- bb14 : {
164+ bb19 : {
144165 StorageDead(_2); // scope 0 at $DIR/match_false_edges.rs:+6:6 : +6:7
145166 StorageDead(_1); // scope 0 at $DIR/match_false_edges.rs:+6:6 : +6:7
146167 _0 = const (); // scope 0 at $DIR/match_false_edges.rs:+0:11 : +7:2
147168 return; // scope 0 at $DIR/match_false_edges.rs:+7:2 : +7:2
148169 }
149170
150- bb15 (cleanup) : {
171+ bb20 (cleanup) : {
151172 resume; // scope 0 at $DIR/match_false_edges.rs:+0:1 : +7:2
152173 }
153174}
0 commit comments