1 // MIR for `foo` after Inline
3 fn foo(_1: T, _2: i32) -> (i32, T) {
4 debug t => _1; // in scope 0 at $DIR/inline_closure_captures.rs:+0:17: +0:18
5 debug q => _2; // in scope 0 at $DIR/inline_closure_captures.rs:+0:23: +0:24
6 let mut _0: (i32, T); // return place in scope 0 at $DIR/inline_closure_captures.rs:+0:34: +0:42
7 let _3: [closure@foo<T>::{closure#0}]; // in scope 0 at $DIR/inline_closure_captures.rs:+1:9: +1:10
8 let mut _4: &i32; // in scope 0 at $DIR/inline_closure_captures.rs:+1:13: +1:24
9 let mut _5: &T; // in scope 0 at $DIR/inline_closure_captures.rs:+1:13: +1:24
10 let mut _6: &[closure@foo<T>::{closure#0}]; // in scope 0 at $DIR/inline_closure_captures.rs:+2:5: +2:6
11 let mut _7: (i32,); // in scope 0 at $DIR/inline_closure_captures.rs:+2:5: +2:9
12 let mut _8: i32; // in scope 0 at $DIR/inline_closure_captures.rs:+2:7: +2:8
13 let mut _9: i32; // in scope 0 at $DIR/inline_closure_captures.rs:+2:5: +2:9
15 debug x => _3; // in scope 1 at $DIR/inline_closure_captures.rs:+1:9: +1:10
16 scope 2 (inlined foo::<T>::{closure#0}) { // at $DIR/inline_closure_captures.rs:12:5: 12:9
17 debug _q => _9; // in scope 2 at $DIR/inline_closure_captures.rs:+1:14: +1:16
18 debug q => (*((*_6).0: &i32)); // in scope 2 at $DIR/inline_closure_captures.rs:+0:23: +0:24
19 debug t => (*((*_6).1: &T)); // in scope 2 at $DIR/inline_closure_captures.rs:+0:17: +0:18
20 let mut _10: i32; // in scope 2 at $DIR/inline_closure_captures.rs:+1:19: +1:20
21 let mut _11: T; // in scope 2 at $DIR/inline_closure_captures.rs:+1:22: +1:23
22 let mut _12: &i32; // in scope 2 at $DIR/inline_closure_captures.rs:+1:13: +1:24
23 let mut _13: &T; // in scope 2 at $DIR/inline_closure_captures.rs:+1:13: +1:24
28 StorageLive(_3); // scope 0 at $DIR/inline_closure_captures.rs:+1:9: +1:10
29 StorageLive(_4); // scope 0 at $DIR/inline_closure_captures.rs:+1:13: +1:24
30 _4 = &_2; // scope 0 at $DIR/inline_closure_captures.rs:+1:13: +1:24
31 StorageLive(_5); // scope 0 at $DIR/inline_closure_captures.rs:+1:13: +1:24
32 _5 = &_1; // scope 0 at $DIR/inline_closure_captures.rs:+1:13: +1:24
33 Deinit(_3); // scope 0 at $DIR/inline_closure_captures.rs:+1:13: +1:24
34 (_3.0: &i32) = move _4; // scope 0 at $DIR/inline_closure_captures.rs:+1:13: +1:24
35 (_3.1: &T) = move _5; // scope 0 at $DIR/inline_closure_captures.rs:+1:13: +1:24
36 StorageDead(_5); // scope 0 at $DIR/inline_closure_captures.rs:+1:16: +1:17
37 StorageDead(_4); // scope 0 at $DIR/inline_closure_captures.rs:+1:16: +1:17
38 StorageLive(_6); // scope 1 at $DIR/inline_closure_captures.rs:+2:5: +2:6
39 _6 = &_3; // scope 1 at $DIR/inline_closure_captures.rs:+2:5: +2:6
40 StorageLive(_7); // scope 1 at $DIR/inline_closure_captures.rs:+2:5: +2:9
41 StorageLive(_8); // scope 1 at $DIR/inline_closure_captures.rs:+2:7: +2:8
42 _8 = _2; // scope 1 at $DIR/inline_closure_captures.rs:+2:7: +2:8
43 Deinit(_7); // scope 1 at $DIR/inline_closure_captures.rs:+2:5: +2:9
44 (_7.0: i32) = move _8; // scope 1 at $DIR/inline_closure_captures.rs:+2:5: +2:9
45 StorageLive(_9); // scope 1 at $DIR/inline_closure_captures.rs:+2:5: +2:9
46 _9 = move (_7.0: i32); // scope 1 at $DIR/inline_closure_captures.rs:+2:5: +2:9
47 StorageLive(_10); // scope 2 at $DIR/inline_closure_captures.rs:+1:19: +1:20
48 _12 = deref_copy ((*_6).0: &i32); // scope 2 at $DIR/inline_closure_captures.rs:+1:19: +1:20
49 _10 = (*_12); // scope 2 at $DIR/inline_closure_captures.rs:+1:19: +1:20
50 StorageLive(_11); // scope 2 at $DIR/inline_closure_captures.rs:+1:22: +1:23
51 _13 = deref_copy ((*_6).1: &T); // scope 2 at $DIR/inline_closure_captures.rs:+1:22: +1:23
52 _11 = (*_13); // scope 2 at $DIR/inline_closure_captures.rs:+1:22: +1:23
53 Deinit(_0); // scope 2 at $DIR/inline_closure_captures.rs:+1:18: +1:24
54 (_0.0: i32) = move _10; // scope 2 at $DIR/inline_closure_captures.rs:+1:18: +1:24
55 (_0.1: T) = move _11; // scope 2 at $DIR/inline_closure_captures.rs:+1:18: +1:24
56 StorageDead(_11); // scope 2 at $DIR/inline_closure_captures.rs:+1:23: +1:24
57 StorageDead(_10); // scope 2 at $DIR/inline_closure_captures.rs:+1:23: +1:24
58 StorageDead(_9); // scope 1 at $DIR/inline_closure_captures.rs:+2:5: +2:9
59 StorageDead(_8); // scope 1 at $DIR/inline_closure_captures.rs:+2:8: +2:9
60 StorageDead(_7); // scope 1 at $DIR/inline_closure_captures.rs:+2:8: +2:9
61 StorageDead(_6); // scope 1 at $DIR/inline_closure_captures.rs:+2:8: +2:9
62 StorageDead(_3); // scope 0 at $DIR/inline_closure_captures.rs:+3:1: +3:2
63 return; // scope 0 at $DIR/inline_closure_captures.rs:+3:2: +3:2