]>
Commit | Line | Data |
---|---|---|
3dfed10e XL |
1 | - // MIR for `complicated_match` after SimplifyCfg-initial |
2 | + // MIR for `complicated_match` after ElaborateDrops | |
3 | ||
1b1a35ee | 4 | fn complicated_match(_1: bool, _2: (bool, bool, String)) -> i32 { |
3dfed10e XL |
5 | debug cond => _1; // in scope 0 at $DIR/match-arm-scopes.rs:13:22: 13:26 |
6 | debug items => _2; // in scope 0 at $DIR/match-arm-scopes.rs:13:34: 13:39 | |
7 | let mut _0: i32; // return place in scope 0 at $DIR/match-arm-scopes.rs:13:66: 13:69 | |
8 | let mut _3: &bool; // in scope 0 at $DIR/match-arm-scopes.rs:14:11: 14:16 | |
9 | let mut _4: &bool; // in scope 0 at $DIR/match-arm-scopes.rs:14:11: 14:16 | |
10 | let _5: bool; // in scope 0 at $DIR/match-arm-scopes.rs:15:17: 15:18 | |
11 | let _6: &bool; // in scope 0 at $DIR/match-arm-scopes.rs:15:17: 15:18 | |
12 | let _7: std::string::String; // in scope 0 at $DIR/match-arm-scopes.rs:15:20: 15:21 | |
13 | let _8: &std::string::String; // in scope 0 at $DIR/match-arm-scopes.rs:15:20: 15:21 | |
14 | let mut _9: bool; // in scope 0 at $DIR/match-arm-scopes.rs:15:42: 15:73 | |
15 | let mut _10: bool; // in scope 0 at $DIR/match-arm-scopes.rs:15:45: 15:49 | |
16 | let mut _11: !; // in scope 0 at $DIR/match-arm-scopes.rs:15:52: 15:60 | |
17 | let mut _12: bool; // in scope 0 at $DIR/match-arm-scopes.rs:15:42: 15:73 | |
18 | let mut _13: bool; // in scope 0 at $DIR/match-arm-scopes.rs:15:45: 15:49 | |
19 | let mut _14: !; // in scope 0 at $DIR/match-arm-scopes.rs:15:52: 15:60 | |
20 | let _15: bool; // in scope 0 at $DIR/match-arm-scopes.rs:16:16: 16:17 | |
21 | let _16: std::string::String; // in scope 0 at $DIR/match-arm-scopes.rs:16:19: 16:20 | |
22 | scope 1 { | |
23 | debug a => _5; // in scope 1 at $DIR/match-arm-scopes.rs:15:17: 15:18 | |
24 | debug a => _6; // in scope 1 at $DIR/match-arm-scopes.rs:15:17: 15:18 | |
25 | debug s => _7; // in scope 1 at $DIR/match-arm-scopes.rs:15:20: 15:21 | |
26 | debug s => _8; // in scope 1 at $DIR/match-arm-scopes.rs:15:20: 15:21 | |
27 | } | |
28 | scope 2 { | |
29 | debug b => _15; // in scope 2 at $DIR/match-arm-scopes.rs:16:16: 16:17 | |
30 | debug t => _16; // in scope 2 at $DIR/match-arm-scopes.rs:16:19: 16:20 | |
31 | } | |
32 | ||
33 | bb0: { | |
cdc7bbd5 | 34 | - FakeRead(ForMatchedPlace(None), _2); // scope 0 at $DIR/match-arm-scopes.rs:14:11: 14:16 |
94222f64 XL |
35 | - switchInt((_2.0: bool)) -> [false: bb1, otherwise: bb2]; // scope 0 at $DIR/match-arm-scopes.rs:14:5: 14:16 |
36 | + switchInt((_2.0: bool)) -> [false: bb5, otherwise: bb1]; // scope 0 at $DIR/match-arm-scopes.rs:14:5: 14:16 | |
3dfed10e XL |
37 | } |
38 | ||
29967ef6 XL |
39 | bb1: { |
40 | - falseEdge -> [real: bb8, imaginary: bb3]; // scope 0 at $DIR/match-arm-scopes.rs:15:9: 15:22 | |
94222f64 | 41 | + switchInt((_2.1: bool)) -> [false: bb10, otherwise: bb2]; // scope 0 at $DIR/match-arm-scopes.rs:14:5: 14:16 |
3dfed10e XL |
42 | } |
43 | ||
44 | bb2: { | |
94222f64 XL |
45 | - switchInt((_2.1: bool)) -> [false: bb3, otherwise: bb4]; // scope 0 at $DIR/match-arm-scopes.rs:14:5: 14:16 |
46 | + switchInt((_2.0: bool)) -> [false: bb3, otherwise: bb17]; // scope 0 at $DIR/match-arm-scopes.rs:14:5: 14:16 | |
3dfed10e XL |
47 | } |
48 | ||
49 | bb3: { | |
5869c6ff | 50 | - falseEdge -> [real: bb13, imaginary: bb5]; // scope 0 at $DIR/match-arm-scopes.rs:15:25: 15:38 |
3dfed10e XL |
51 | - } |
52 | - | |
29967ef6 | 53 | - bb4: { |
94222f64 | 54 | - switchInt((_2.0: bool)) -> [false: bb6, otherwise: bb5]; // scope 0 at $DIR/match-arm-scopes.rs:14:5: 14:16 |
3dfed10e XL |
55 | - } |
56 | - | |
29967ef6 | 57 | - bb5: { |
5869c6ff | 58 | - falseEdge -> [real: bb20, imaginary: bb6]; // scope 0 at $DIR/match-arm-scopes.rs:16:9: 16:21 |
3dfed10e XL |
59 | - } |
60 | - | |
29967ef6 | 61 | - bb6: { |
3dfed10e XL |
62 | StorageLive(_15); // scope 0 at $DIR/match-arm-scopes.rs:16:32: 16:33 |
63 | _15 = (_2.1: bool); // scope 0 at $DIR/match-arm-scopes.rs:16:32: 16:33 | |
64 | StorageLive(_16); // scope 0 at $DIR/match-arm-scopes.rs:16:35: 16:36 | |
65 | _16 = move (_2.2: std::string::String); // scope 0 at $DIR/match-arm-scopes.rs:16:35: 16:36 | |
5869c6ff | 66 | - goto -> bb19; // scope 0 at $DIR/match-arm-scopes.rs:14:5: 17:6 |
29967ef6 | 67 | + goto -> bb16; // scope 0 at $DIR/match-arm-scopes.rs:14:5: 17:6 |
3dfed10e XL |
68 | } |
69 | ||
29967ef6 XL |
70 | - bb7: { |
71 | + bb4: { | |
3dfed10e | 72 | _0 = const 1_i32; // scope 1 at $DIR/match-arm-scopes.rs:15:77: 15:78 |
5869c6ff | 73 | - drop(_7) -> [return: bb18, unwind: bb25]; // scope 0 at $DIR/match-arm-scopes.rs:15:77: 15:78 |
29967ef6 | 74 | + drop(_7) -> [return: bb15, unwind: bb22]; // scope 0 at $DIR/match-arm-scopes.rs:15:77: 15:78 |
3dfed10e XL |
75 | } |
76 | ||
29967ef6 XL |
77 | - bb8: { |
78 | + bb5: { | |
3dfed10e XL |
79 | StorageLive(_6); // scope 0 at $DIR/match-arm-scopes.rs:15:17: 15:18 |
80 | _6 = &(_2.1: bool); // scope 0 at $DIR/match-arm-scopes.rs:15:17: 15:18 | |
81 | StorageLive(_8); // scope 0 at $DIR/match-arm-scopes.rs:15:20: 15:21 | |
82 | _8 = &(_2.2: std::string::String); // scope 0 at $DIR/match-arm-scopes.rs:15:20: 15:21 | |
83 | - _3 = &shallow (_2.0: bool); // scope 0 at $DIR/match-arm-scopes.rs:14:11: 14:16 | |
84 | - _4 = &shallow (_2.1: bool); // scope 0 at $DIR/match-arm-scopes.rs:14:11: 14:16 | |
85 | StorageLive(_9); // scope 0 at $DIR/match-arm-scopes.rs:15:42: 15:73 | |
86 | StorageLive(_10); // scope 0 at $DIR/match-arm-scopes.rs:15:45: 15:49 | |
87 | _10 = _1; // scope 0 at $DIR/match-arm-scopes.rs:15:45: 15:49 | |
94222f64 XL |
88 | - switchInt(move _10) -> [false: bb10, otherwise: bb9]; // scope 0 at $DIR/match-arm-scopes.rs:15:45: 15:49 |
89 | + switchInt(move _10) -> [false: bb7, otherwise: bb6]; // scope 0 at $DIR/match-arm-scopes.rs:15:45: 15:49 | |
3dfed10e XL |
90 | } |
91 | ||
29967ef6 | 92 | - bb9: { |
29967ef6 | 93 | + bb6: { |
5869c6ff | 94 | _0 = const 3_i32; // scope 0 at $DIR/match-arm-scopes.rs:15:59: 15:60 |
3dfed10e | 95 | StorageDead(_10); // scope 0 at $DIR/match-arm-scopes.rs:15:72: 15:73 |
94222f64 | 96 | StorageDead(_9); // scope 0 at $DIR/match-arm-scopes.rs:15:72: 15:73 |
17df50a5 XL |
97 | - goto -> bb23; // scope 0 at no-location |
98 | + goto -> bb20; // scope 0 at no-location | |
3dfed10e XL |
99 | } |
100 | ||
5869c6ff | 101 | - bb10: { |
29967ef6 | 102 | + bb7: { |
5869c6ff | 103 | _9 = (*_6); // scope 0 at $DIR/match-arm-scopes.rs:15:70: 15:71 |
5869c6ff XL |
104 | - switchInt(move _9) -> [false: bb12, otherwise: bb11]; // scope 0 at $DIR/match-arm-scopes.rs:15:42: 15:73 |
105 | + switchInt(move _9) -> [false: bb9, otherwise: bb8]; // scope 0 at $DIR/match-arm-scopes.rs:15:42: 15:73 | |
3dfed10e XL |
106 | } |
107 | ||
5869c6ff | 108 | - bb11: { |
29967ef6 | 109 | + bb8: { |
94222f64 XL |
110 | StorageDead(_10); // scope 0 at $DIR/match-arm-scopes.rs:15:72: 15:73 |
111 | StorageDead(_9); // scope 0 at $DIR/match-arm-scopes.rs:15:72: 15:73 | |
3dfed10e XL |
112 | - FakeRead(ForMatchGuard, _3); // scope 0 at $DIR/match-arm-scopes.rs:15:72: 15:73 |
113 | - FakeRead(ForMatchGuard, _4); // scope 0 at $DIR/match-arm-scopes.rs:15:72: 15:73 | |
114 | - FakeRead(ForGuardBinding, _6); // scope 0 at $DIR/match-arm-scopes.rs:15:72: 15:73 | |
115 | - FakeRead(ForGuardBinding, _8); // scope 0 at $DIR/match-arm-scopes.rs:15:72: 15:73 | |
116 | StorageLive(_5); // scope 0 at $DIR/match-arm-scopes.rs:15:17: 15:18 | |
117 | _5 = (_2.1: bool); // scope 0 at $DIR/match-arm-scopes.rs:15:17: 15:18 | |
118 | StorageLive(_7); // scope 0 at $DIR/match-arm-scopes.rs:15:20: 15:21 | |
119 | _7 = move (_2.2: std::string::String); // scope 0 at $DIR/match-arm-scopes.rs:15:20: 15:21 | |
29967ef6 XL |
120 | - goto -> bb7; // scope 0 at $DIR/match-arm-scopes.rs:14:5: 17:6 |
121 | + goto -> bb4; // scope 0 at $DIR/match-arm-scopes.rs:14:5: 17:6 | |
3dfed10e XL |
122 | } |
123 | ||
5869c6ff | 124 | - bb12: { |
29967ef6 | 125 | + bb9: { |
94222f64 XL |
126 | StorageDead(_10); // scope 0 at $DIR/match-arm-scopes.rs:15:72: 15:73 |
127 | StorageDead(_9); // scope 0 at $DIR/match-arm-scopes.rs:15:72: 15:73 | |
3dfed10e XL |
128 | StorageDead(_8); // scope 0 at $DIR/match-arm-scopes.rs:15:77: 15:78 |
129 | StorageDead(_6); // scope 0 at $DIR/match-arm-scopes.rs:15:77: 15:78 | |
29967ef6 XL |
130 | - falseEdge -> [real: bb2, imaginary: bb3]; // scope 0 at $DIR/match-arm-scopes.rs:15:42: 15:73 |
131 | + goto -> bb1; // scope 0 at $DIR/match-arm-scopes.rs:15:42: 15:73 | |
3dfed10e XL |
132 | } |
133 | ||
5869c6ff | 134 | - bb13: { |
29967ef6 | 135 | + bb10: { |
3dfed10e XL |
136 | StorageLive(_6); // scope 0 at $DIR/match-arm-scopes.rs:15:26: 15:27 |
137 | _6 = &(_2.0: bool); // scope 0 at $DIR/match-arm-scopes.rs:15:26: 15:27 | |
138 | StorageLive(_8); // scope 0 at $DIR/match-arm-scopes.rs:15:36: 15:37 | |
139 | _8 = &(_2.2: std::string::String); // scope 0 at $DIR/match-arm-scopes.rs:15:36: 15:37 | |
140 | - _3 = &shallow (_2.0: bool); // scope 0 at $DIR/match-arm-scopes.rs:14:11: 14:16 | |
141 | - _4 = &shallow (_2.1: bool); // scope 0 at $DIR/match-arm-scopes.rs:14:11: 14:16 | |
142 | StorageLive(_12); // scope 0 at $DIR/match-arm-scopes.rs:15:42: 15:73 | |
143 | StorageLive(_13); // scope 0 at $DIR/match-arm-scopes.rs:15:45: 15:49 | |
144 | _13 = _1; // scope 0 at $DIR/match-arm-scopes.rs:15:45: 15:49 | |
94222f64 XL |
145 | - switchInt(move _13) -> [false: bb15, otherwise: bb14]; // scope 0 at $DIR/match-arm-scopes.rs:15:45: 15:49 |
146 | + switchInt(move _13) -> [false: bb12, otherwise: bb11]; // scope 0 at $DIR/match-arm-scopes.rs:15:45: 15:49 | |
3dfed10e XL |
147 | } |
148 | ||
5869c6ff | 149 | - bb14: { |
29967ef6 | 150 | + bb11: { |
5869c6ff | 151 | _0 = const 3_i32; // scope 0 at $DIR/match-arm-scopes.rs:15:59: 15:60 |
3dfed10e | 152 | StorageDead(_13); // scope 0 at $DIR/match-arm-scopes.rs:15:72: 15:73 |
94222f64 | 153 | StorageDead(_12); // scope 0 at $DIR/match-arm-scopes.rs:15:72: 15:73 |
17df50a5 XL |
154 | - goto -> bb23; // scope 0 at no-location |
155 | + goto -> bb20; // scope 0 at no-location | |
3dfed10e XL |
156 | } |
157 | ||
5869c6ff | 158 | - bb15: { |
29967ef6 | 159 | + bb12: { |
5869c6ff | 160 | _12 = (*_6); // scope 0 at $DIR/match-arm-scopes.rs:15:70: 15:71 |
5869c6ff XL |
161 | - switchInt(move _12) -> [false: bb17, otherwise: bb16]; // scope 0 at $DIR/match-arm-scopes.rs:15:42: 15:73 |
162 | + switchInt(move _12) -> [false: bb14, otherwise: bb13]; // scope 0 at $DIR/match-arm-scopes.rs:15:42: 15:73 | |
3dfed10e XL |
163 | } |
164 | ||
5869c6ff | 165 | - bb16: { |
29967ef6 | 166 | + bb13: { |
94222f64 XL |
167 | StorageDead(_13); // scope 0 at $DIR/match-arm-scopes.rs:15:72: 15:73 |
168 | StorageDead(_12); // scope 0 at $DIR/match-arm-scopes.rs:15:72: 15:73 | |
3dfed10e XL |
169 | - FakeRead(ForMatchGuard, _3); // scope 0 at $DIR/match-arm-scopes.rs:15:72: 15:73 |
170 | - FakeRead(ForMatchGuard, _4); // scope 0 at $DIR/match-arm-scopes.rs:15:72: 15:73 | |
171 | - FakeRead(ForGuardBinding, _6); // scope 0 at $DIR/match-arm-scopes.rs:15:72: 15:73 | |
172 | - FakeRead(ForGuardBinding, _8); // scope 0 at $DIR/match-arm-scopes.rs:15:72: 15:73 | |
173 | StorageLive(_5); // scope 0 at $DIR/match-arm-scopes.rs:15:26: 15:27 | |
174 | _5 = (_2.0: bool); // scope 0 at $DIR/match-arm-scopes.rs:15:26: 15:27 | |
175 | StorageLive(_7); // scope 0 at $DIR/match-arm-scopes.rs:15:36: 15:37 | |
176 | _7 = move (_2.2: std::string::String); // scope 0 at $DIR/match-arm-scopes.rs:15:36: 15:37 | |
29967ef6 XL |
177 | - goto -> bb7; // scope 0 at $DIR/match-arm-scopes.rs:14:5: 17:6 |
178 | + goto -> bb4; // scope 0 at $DIR/match-arm-scopes.rs:14:5: 17:6 | |
3dfed10e XL |
179 | } |
180 | ||
5869c6ff | 181 | - bb17: { |
29967ef6 | 182 | + bb14: { |
94222f64 XL |
183 | StorageDead(_13); // scope 0 at $DIR/match-arm-scopes.rs:15:72: 15:73 |
184 | StorageDead(_12); // scope 0 at $DIR/match-arm-scopes.rs:15:72: 15:73 | |
3dfed10e XL |
185 | StorageDead(_8); // scope 0 at $DIR/match-arm-scopes.rs:15:77: 15:78 |
186 | StorageDead(_6); // scope 0 at $DIR/match-arm-scopes.rs:15:77: 15:78 | |
29967ef6 XL |
187 | - falseEdge -> [real: bb4, imaginary: bb5]; // scope 0 at $DIR/match-arm-scopes.rs:15:42: 15:73 |
188 | + goto -> bb2; // scope 0 at $DIR/match-arm-scopes.rs:15:42: 15:73 | |
3dfed10e XL |
189 | } |
190 | ||
5869c6ff | 191 | - bb18: { |
29967ef6 | 192 | + bb15: { |
3dfed10e XL |
193 | StorageDead(_7); // scope 0 at $DIR/match-arm-scopes.rs:15:77: 15:78 |
194 | StorageDead(_5); // scope 0 at $DIR/match-arm-scopes.rs:15:77: 15:78 | |
195 | StorageDead(_8); // scope 0 at $DIR/match-arm-scopes.rs:15:77: 15:78 | |
196 | StorageDead(_6); // scope 0 at $DIR/match-arm-scopes.rs:15:77: 15:78 | |
94222f64 XL |
197 | - goto -> bb22; // scope 0 at $DIR/match-arm-scopes.rs:15:77: 15:78 |
198 | + goto -> bb19; // scope 0 at $DIR/match-arm-scopes.rs:15:77: 15:78 | |
3dfed10e XL |
199 | } |
200 | ||
5869c6ff | 201 | - bb19: { |
29967ef6 | 202 | + bb16: { |
3dfed10e | 203 | _0 = const 2_i32; // scope 2 at $DIR/match-arm-scopes.rs:16:41: 16:42 |
5869c6ff | 204 | - drop(_16) -> [return: bb21, unwind: bb25]; // scope 0 at $DIR/match-arm-scopes.rs:16:41: 16:42 |
29967ef6 | 205 | + drop(_16) -> [return: bb18, unwind: bb22]; // scope 0 at $DIR/match-arm-scopes.rs:16:41: 16:42 |
3dfed10e XL |
206 | } |
207 | ||
5869c6ff | 208 | - bb20: { |
29967ef6 | 209 | + bb17: { |
3dfed10e XL |
210 | StorageLive(_15); // scope 0 at $DIR/match-arm-scopes.rs:16:16: 16:17 |
211 | _15 = (_2.1: bool); // scope 0 at $DIR/match-arm-scopes.rs:16:16: 16:17 | |
212 | StorageLive(_16); // scope 0 at $DIR/match-arm-scopes.rs:16:19: 16:20 | |
213 | _16 = move (_2.2: std::string::String); // scope 0 at $DIR/match-arm-scopes.rs:16:19: 16:20 | |
5869c6ff | 214 | - goto -> bb19; // scope 0 at $DIR/match-arm-scopes.rs:14:5: 17:6 |
29967ef6 | 215 | + goto -> bb16; // scope 0 at $DIR/match-arm-scopes.rs:14:5: 17:6 |
3dfed10e XL |
216 | } |
217 | ||
5869c6ff | 218 | - bb21: { |
29967ef6 | 219 | + bb18: { |
3dfed10e XL |
220 | StorageDead(_16); // scope 0 at $DIR/match-arm-scopes.rs:16:41: 16:42 |
221 | StorageDead(_15); // scope 0 at $DIR/match-arm-scopes.rs:16:41: 16:42 | |
94222f64 XL |
222 | - goto -> bb22; // scope 0 at $DIR/match-arm-scopes.rs:16:41: 16:42 |
223 | + goto -> bb19; // scope 0 at $DIR/match-arm-scopes.rs:16:41: 16:42 | |
3dfed10e XL |
224 | } |
225 | ||
5869c6ff XL |
226 | - bb22: { |
227 | - drop(_2) -> [return: bb24, unwind: bb26]; // scope 0 at $DIR/match-arm-scopes.rs:18:1: 18:2 | |
29967ef6 XL |
228 | + bb19: { |
229 | + goto -> bb26; // scope 0 at $DIR/match-arm-scopes.rs:18:1: 18:2 | |
230 | } | |
231 | ||
5869c6ff | 232 | - bb23: { |
29967ef6 XL |
233 | + bb20: { |
234 | StorageDead(_8); // scope 0 at $DIR/match-arm-scopes.rs:15:77: 15:78 | |
235 | StorageDead(_6); // scope 0 at $DIR/match-arm-scopes.rs:15:77: 15:78 | |
5869c6ff | 236 | - drop(_2) -> [return: bb24, unwind: bb26]; // scope 0 at $DIR/match-arm-scopes.rs:18:1: 18:2 |
29967ef6 XL |
237 | + drop(_2) -> [return: bb21, unwind: bb23]; // scope 0 at $DIR/match-arm-scopes.rs:18:1: 18:2 |
238 | } | |
239 | ||
5869c6ff | 240 | - bb24: { |
29967ef6 XL |
241 | + bb21: { |
242 | return; // scope 0 at $DIR/match-arm-scopes.rs:18:2: 18:2 | |
243 | } | |
244 | ||
5869c6ff XL |
245 | - bb25 (cleanup): { |
246 | - drop(_2) -> bb26; // scope 0 at $DIR/match-arm-scopes.rs:18:1: 18:2 | |
29967ef6 XL |
247 | + bb22 (cleanup): { |
248 | + goto -> bb27; // scope 0 at $DIR/match-arm-scopes.rs:18:1: 18:2 | |
249 | } | |
250 | ||
5869c6ff | 251 | - bb26 (cleanup): { |
29967ef6 XL |
252 | + bb23 (cleanup): { |
253 | resume; // scope 0 at $DIR/match-arm-scopes.rs:13:1: 18:2 | |
3dfed10e XL |
254 | + } |
255 | + | |
29967ef6 XL |
256 | + bb24: { |
257 | + goto -> bb21; // scope 0 at $DIR/match-arm-scopes.rs:18:1: 18:2 | |
3dfed10e XL |
258 | + } |
259 | + | |
260 | + bb25 (cleanup): { | |
29967ef6 | 261 | + goto -> bb23; // scope 0 at $DIR/match-arm-scopes.rs:18:1: 18:2 |
3dfed10e XL |
262 | + } |
263 | + | |
264 | + bb26: { | |
29967ef6 | 265 | + goto -> bb24; // scope 0 at $DIR/match-arm-scopes.rs:18:1: 18:2 |
3dfed10e XL |
266 | + } |
267 | + | |
268 | + bb27 (cleanup): { | |
29967ef6 | 269 | + goto -> bb23; // scope 0 at $DIR/match-arm-scopes.rs:18:1: 18:2 |
3dfed10e XL |
270 | } |
271 | } | |
272 |