1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
|
// MIR for `address_of_reborrow` after SimplifyCfg-initial
| User Type Annotations
| 0: user_ty: Canonical { value: Ty(*const ^0), max_universe: U0, variables: [CanonicalVarInfo { kind: Ty(General(U0)) }] }, span: $DIR/address_of.rs:7:5: 7:18, inferred_ty: *const [i32; 10]
| 1: user_ty: Canonical { value: Ty(*const dyn std::marker::Send), max_universe: U0, variables: [CanonicalVarInfo { kind: Region(U0) }] }, span: $DIR/address_of.rs:9:5: 9:25, inferred_ty: *const dyn std::marker::Send
| 2: user_ty: Canonical { value: Ty(*const ^0), max_universe: U0, variables: [CanonicalVarInfo { kind: Ty(General(U0)) }] }, span: $DIR/address_of.rs:13:12: 13:20, inferred_ty: *const [i32; 10]
| 3: user_ty: Canonical { value: Ty(*const ^0), max_universe: U0, variables: [CanonicalVarInfo { kind: Ty(General(U0)) }] }, span: $DIR/address_of.rs:13:12: 13:20, inferred_ty: *const [i32; 10]
| 4: user_ty: Canonical { value: Ty(*const [i32; 10]), max_universe: U0, variables: [] }, span: $DIR/address_of.rs:14:12: 14:28, inferred_ty: *const [i32; 10]
| 5: user_ty: Canonical { value: Ty(*const [i32; 10]), max_universe: U0, variables: [] }, span: $DIR/address_of.rs:14:12: 14:28, inferred_ty: *const [i32; 10]
| 6: user_ty: Canonical { value: Ty(*const dyn std::marker::Send), max_universe: U0, variables: [CanonicalVarInfo { kind: Region(U0) }] }, span: $DIR/address_of.rs:15:12: 15:27, inferred_ty: *const dyn std::marker::Send
| 7: user_ty: Canonical { value: Ty(*const dyn std::marker::Send), max_universe: U0, variables: [CanonicalVarInfo { kind: Region(U0) }] }, span: $DIR/address_of.rs:15:12: 15:27, inferred_ty: *const dyn std::marker::Send
| 8: user_ty: Canonical { value: Ty(*const [i32]), max_universe: U0, variables: [] }, span: $DIR/address_of.rs:16:12: 16:24, inferred_ty: *const [i32]
| 9: user_ty: Canonical { value: Ty(*const [i32]), max_universe: U0, variables: [] }, span: $DIR/address_of.rs:16:12: 16:24, inferred_ty: *const [i32]
| 10: user_ty: Canonical { value: Ty(*const ^0), max_universe: U0, variables: [CanonicalVarInfo { kind: Ty(General(U0)) }] }, span: $DIR/address_of.rs:18:5: 18:18, inferred_ty: *const [i32; 10]
| 11: user_ty: Canonical { value: Ty(*const dyn std::marker::Send), max_universe: U0, variables: [CanonicalVarInfo { kind: Region(U0) }] }, span: $DIR/address_of.rs:20:5: 20:25, inferred_ty: *const dyn std::marker::Send
| 12: user_ty: Canonical { value: Ty(*const ^0), max_universe: U0, variables: [CanonicalVarInfo { kind: Ty(General(U0)) }] }, span: $DIR/address_of.rs:23:12: 23:20, inferred_ty: *const [i32; 10]
| 13: user_ty: Canonical { value: Ty(*const ^0), max_universe: U0, variables: [CanonicalVarInfo { kind: Ty(General(U0)) }] }, span: $DIR/address_of.rs:23:12: 23:20, inferred_ty: *const [i32; 10]
| 14: user_ty: Canonical { value: Ty(*const [i32; 10]), max_universe: U0, variables: [] }, span: $DIR/address_of.rs:24:12: 24:28, inferred_ty: *const [i32; 10]
| 15: user_ty: Canonical { value: Ty(*const [i32; 10]), max_universe: U0, variables: [] }, span: $DIR/address_of.rs:24:12: 24:28, inferred_ty: *const [i32; 10]
| 16: user_ty: Canonical { value: Ty(*const dyn std::marker::Send), max_universe: U0, variables: [CanonicalVarInfo { kind: Region(U0) }] }, span: $DIR/address_of.rs:25:12: 25:27, inferred_ty: *const dyn std::marker::Send
| 17: user_ty: Canonical { value: Ty(*const dyn std::marker::Send), max_universe: U0, variables: [CanonicalVarInfo { kind: Region(U0) }] }, span: $DIR/address_of.rs:25:12: 25:27, inferred_ty: *const dyn std::marker::Send
| 18: user_ty: Canonical { value: Ty(*const [i32]), max_universe: U0, variables: [] }, span: $DIR/address_of.rs:26:12: 26:24, inferred_ty: *const [i32]
| 19: user_ty: Canonical { value: Ty(*const [i32]), max_universe: U0, variables: [] }, span: $DIR/address_of.rs:26:12: 26:24, inferred_ty: *const [i32]
| 20: user_ty: Canonical { value: Ty(*mut ^0), max_universe: U0, variables: [CanonicalVarInfo { kind: Ty(General(U0)) }] }, span: $DIR/address_of.rs:28:5: 28:16, inferred_ty: *mut [i32; 10]
| 21: user_ty: Canonical { value: Ty(*mut dyn std::marker::Send), max_universe: U0, variables: [CanonicalVarInfo { kind: Region(U0) }] }, span: $DIR/address_of.rs:30:5: 30:23, inferred_ty: *mut dyn std::marker::Send
| 22: user_ty: Canonical { value: Ty(*mut ^0), max_universe: U0, variables: [CanonicalVarInfo { kind: Ty(General(U0)) }] }, span: $DIR/address_of.rs:33:12: 33:18, inferred_ty: *mut [i32; 10]
| 23: user_ty: Canonical { value: Ty(*mut ^0), max_universe: U0, variables: [CanonicalVarInfo { kind: Ty(General(U0)) }] }, span: $DIR/address_of.rs:33:12: 33:18, inferred_ty: *mut [i32; 10]
| 24: user_ty: Canonical { value: Ty(*mut [i32; 10]), max_universe: U0, variables: [] }, span: $DIR/address_of.rs:34:12: 34:26, inferred_ty: *mut [i32; 10]
| 25: user_ty: Canonical { value: Ty(*mut [i32; 10]), max_universe: U0, variables: [] }, span: $DIR/address_of.rs:34:12: 34:26, inferred_ty: *mut [i32; 10]
| 26: user_ty: Canonical { value: Ty(*mut dyn std::marker::Send), max_universe: U0, variables: [CanonicalVarInfo { kind: Region(U0) }] }, span: $DIR/address_of.rs:35:12: 35:25, inferred_ty: *mut dyn std::marker::Send
| 27: user_ty: Canonical { value: Ty(*mut dyn std::marker::Send), max_universe: U0, variables: [CanonicalVarInfo { kind: Region(U0) }] }, span: $DIR/address_of.rs:35:12: 35:25, inferred_ty: *mut dyn std::marker::Send
| 28: user_ty: Canonical { value: Ty(*mut [i32]), max_universe: U0, variables: [] }, span: $DIR/address_of.rs:36:12: 36:22, inferred_ty: *mut [i32]
| 29: user_ty: Canonical { value: Ty(*mut [i32]), max_universe: U0, variables: [] }, span: $DIR/address_of.rs:36:12: 36:22, inferred_ty: *mut [i32]
|
fn address_of_reborrow() -> () {
let mut _0: ();
let _1: &[i32; 10];
let _2: [i32; 10];
let mut _4: [i32; 10];
let _5: *const [i32; 10];
let mut _6: *const [i32; 10];
let _7: *const [i32; 10];
let _8: *const dyn std::marker::Send;
let mut _9: *const dyn std::marker::Send;
let mut _10: *const [i32; 10];
let _11: *const [i32];
let mut _12: *const [i32; 10];
let _13: *const i32;
let mut _14: *const [i32; 10];
let mut _18: *const [i32; 10];
let mut _20: *const [i32; 10];
let _21: *const [i32; 10];
let mut _22: *const [i32; 10];
let _23: *const [i32; 10];
let _24: *const dyn std::marker::Send;
let mut _25: *const dyn std::marker::Send;
let mut _26: *const [i32; 10];
let _27: *const [i32];
let mut _28: *const [i32; 10];
let mut _32: *const [i32; 10];
let mut _34: *const [i32; 10];
let _35: *mut [i32; 10];
let mut _36: *mut [i32; 10];
let _37: *mut [i32; 10];
let _38: *mut dyn std::marker::Send;
let mut _39: *mut dyn std::marker::Send;
let mut _40: *mut [i32; 10];
let _41: *mut [i32];
let mut _42: *mut [i32; 10];
let mut _46: *mut [i32; 10];
let mut _48: *mut [i32; 10];
scope 1 {
debug y => _1;
let mut _3: &mut [i32; 10];
scope 2 {
debug z => _3;
let _15: *const [i32; 10] as UserTypeProjection { base: UserType(2), projs: [] };
scope 3 {
debug p => _15;
let _16: *const [i32; 10] as UserTypeProjection { base: UserType(4), projs: [] };
scope 4 {
debug p => _16;
let _17: *const dyn std::marker::Send as UserTypeProjection { base: UserType(6), projs: [] };
scope 5 {
debug p => _17;
let _19: *const [i32] as UserTypeProjection { base: UserType(8), projs: [] };
scope 6 {
debug p => _19;
let _29: *const [i32; 10] as UserTypeProjection { base: UserType(12), projs: [] };
scope 7 {
debug p => _29;
let _30: *const [i32; 10] as UserTypeProjection { base: UserType(14), projs: [] };
scope 8 {
debug p => _30;
let _31: *const dyn std::marker::Send as UserTypeProjection { base: UserType(16), projs: [] };
scope 9 {
debug p => _31;
let _33: *const [i32] as UserTypeProjection { base: UserType(18), projs: [] };
scope 10 {
debug p => _33;
let _43: *mut [i32; 10] as UserTypeProjection { base: UserType(22), projs: [] };
scope 11 {
debug p => _43;
let _44: *mut [i32; 10] as UserTypeProjection { base: UserType(24), projs: [] };
scope 12 {
debug p => _44;
let _45: *mut dyn std::marker::Send as UserTypeProjection { base: UserType(26), projs: [] };
scope 13 {
debug p => _45;
let _47: *mut [i32] as UserTypeProjection { base: UserType(28), projs: [] };
scope 14 {
debug p => _47;
}
}
}
}
}
}
}
}
}
}
}
}
}
}
bb0: {
StorageLive(_1);
StorageLive(_2);
_2 = [const 0_i32; 10];
_1 = &_2;
FakeRead(ForLet(None), _1);
StorageLive(_3);
StorageLive(_4);
_4 = [const 0_i32; 10];
_3 = &mut _4;
FakeRead(ForLet(None), _3);
StorageLive(_5);
StorageLive(_6);
_6 = &raw const (*_1);
AscribeUserType(_6, o, UserTypeProjection { base: UserType(0), projs: [] });
_5 = _6;
StorageDead(_6);
StorageDead(_5);
StorageLive(_7);
_7 = &raw const (*_1);
StorageDead(_7);
StorageLive(_8);
StorageLive(_9);
StorageLive(_10);
_10 = &raw const (*_1);
_9 = move _10 as *const dyn std::marker::Send (PointerCoercion(Unsize));
StorageDead(_10);
AscribeUserType(_9, o, UserTypeProjection { base: UserType(1), projs: [] });
_8 = _9;
StorageDead(_9);
StorageDead(_8);
StorageLive(_11);
StorageLive(_12);
_12 = &raw const (*_1);
_11 = move _12 as *const [i32] (PointerCoercion(Unsize));
StorageDead(_12);
StorageDead(_11);
StorageLive(_13);
StorageLive(_14);
_14 = &raw const (*_1);
_13 = move _14 as *const i32 (PointerCoercion(ArrayToPointer));
StorageDead(_14);
StorageDead(_13);
StorageLive(_15);
_15 = &raw const (*_1);
FakeRead(ForLet(None), _15);
AscribeUserType(_15, o, UserTypeProjection { base: UserType(3), projs: [] });
StorageLive(_16);
_16 = &raw const (*_1);
FakeRead(ForLet(None), _16);
AscribeUserType(_16, o, UserTypeProjection { base: UserType(5), projs: [] });
StorageLive(_17);
StorageLive(_18);
_18 = &raw const (*_1);
_17 = move _18 as *const dyn std::marker::Send (PointerCoercion(Unsize));
StorageDead(_18);
FakeRead(ForLet(None), _17);
AscribeUserType(_17, o, UserTypeProjection { base: UserType(7), projs: [] });
StorageLive(_19);
StorageLive(_20);
_20 = &raw const (*_1);
_19 = move _20 as *const [i32] (PointerCoercion(Unsize));
StorageDead(_20);
FakeRead(ForLet(None), _19);
AscribeUserType(_19, o, UserTypeProjection { base: UserType(9), projs: [] });
StorageLive(_21);
StorageLive(_22);
_22 = &raw const (*_3);
AscribeUserType(_22, o, UserTypeProjection { base: UserType(10), projs: [] });
_21 = _22;
StorageDead(_22);
StorageDead(_21);
StorageLive(_23);
_23 = &raw const (*_3);
StorageDead(_23);
StorageLive(_24);
StorageLive(_25);
StorageLive(_26);
_26 = &raw const (*_3);
_25 = move _26 as *const dyn std::marker::Send (PointerCoercion(Unsize));
StorageDead(_26);
AscribeUserType(_25, o, UserTypeProjection { base: UserType(11), projs: [] });
_24 = _25;
StorageDead(_25);
StorageDead(_24);
StorageLive(_27);
StorageLive(_28);
_28 = &raw const (*_3);
_27 = move _28 as *const [i32] (PointerCoercion(Unsize));
StorageDead(_28);
StorageDead(_27);
StorageLive(_29);
_29 = &raw const (*_3);
FakeRead(ForLet(None), _29);
AscribeUserType(_29, o, UserTypeProjection { base: UserType(13), projs: [] });
StorageLive(_30);
_30 = &raw const (*_3);
FakeRead(ForLet(None), _30);
AscribeUserType(_30, o, UserTypeProjection { base: UserType(15), projs: [] });
StorageLive(_31);
StorageLive(_32);
_32 = &raw const (*_3);
_31 = move _32 as *const dyn std::marker::Send (PointerCoercion(Unsize));
StorageDead(_32);
FakeRead(ForLet(None), _31);
AscribeUserType(_31, o, UserTypeProjection { base: UserType(17), projs: [] });
StorageLive(_33);
StorageLive(_34);
_34 = &raw const (*_3);
_33 = move _34 as *const [i32] (PointerCoercion(Unsize));
StorageDead(_34);
FakeRead(ForLet(None), _33);
AscribeUserType(_33, o, UserTypeProjection { base: UserType(19), projs: [] });
StorageLive(_35);
StorageLive(_36);
_36 = &raw mut (*_3);
AscribeUserType(_36, o, UserTypeProjection { base: UserType(20), projs: [] });
_35 = _36;
StorageDead(_36);
StorageDead(_35);
StorageLive(_37);
_37 = &raw mut (*_3);
StorageDead(_37);
StorageLive(_38);
StorageLive(_39);
StorageLive(_40);
_40 = &raw mut (*_3);
_39 = move _40 as *mut dyn std::marker::Send (PointerCoercion(Unsize));
StorageDead(_40);
AscribeUserType(_39, o, UserTypeProjection { base: UserType(21), projs: [] });
_38 = _39;
StorageDead(_39);
StorageDead(_38);
StorageLive(_41);
StorageLive(_42);
_42 = &raw mut (*_3);
_41 = move _42 as *mut [i32] (PointerCoercion(Unsize));
StorageDead(_42);
StorageDead(_41);
StorageLive(_43);
_43 = &raw mut (*_3);
FakeRead(ForLet(None), _43);
AscribeUserType(_43, o, UserTypeProjection { base: UserType(23), projs: [] });
StorageLive(_44);
_44 = &raw mut (*_3);
FakeRead(ForLet(None), _44);
AscribeUserType(_44, o, UserTypeProjection { base: UserType(25), projs: [] });
StorageLive(_45);
StorageLive(_46);
_46 = &raw mut (*_3);
_45 = move _46 as *mut dyn std::marker::Send (PointerCoercion(Unsize));
StorageDead(_46);
FakeRead(ForLet(None), _45);
AscribeUserType(_45, o, UserTypeProjection { base: UserType(27), projs: [] });
StorageLive(_47);
StorageLive(_48);
_48 = &raw mut (*_3);
_47 = move _48 as *mut [i32] (PointerCoercion(Unsize));
StorageDead(_48);
FakeRead(ForLet(None), _47);
AscribeUserType(_47, o, UserTypeProjection { base: UserType(29), projs: [] });
_0 = const ();
StorageDead(_47);
StorageDead(_45);
StorageDead(_44);
StorageDead(_43);
StorageDead(_33);
StorageDead(_31);
StorageDead(_30);
StorageDead(_29);
StorageDead(_19);
StorageDead(_17);
StorageDead(_16);
StorageDead(_15);
StorageDead(_4);
StorageDead(_3);
StorageDead(_2);
StorageDead(_1);
return;
}
}
|