]> git.lizzy.rs Git - rust.git/blob - src/test/mir-opt/generator_storage_dead_unwind.main-{closure#0}.StateTransform.before.mir
Rollup merge of #99864 - klensy:bootstrap-art-dupe, r=jyn514
[rust.git] / src / test / mir-opt / generator_storage_dead_unwind.main-{closure#0}.StateTransform.before.mir
1 // MIR for `main::{closure#0}` before StateTransform
2
3 fn main::{closure#0}(_1: [generator@$DIR/generator-storage-dead-unwind.rs:22:16: 22:18], _2: ()) -> ()
4 yields ()
5  {
6     let mut _0: ();                      // return place in scope 0 at $DIR/generator-storage-dead-unwind.rs:+0:19: +0:19
7     let _3: Foo;                         // in scope 0 at $DIR/generator-storage-dead-unwind.rs:+1:13: +1:14
8     let _5: ();                          // in scope 0 at $DIR/generator-storage-dead-unwind.rs:+3:9: +3:14
9     let mut _6: ();                      // in scope 0 at $DIR/generator-storage-dead-unwind.rs:+3:9: +3:14
10     let _7: ();                          // in scope 0 at $DIR/generator-storage-dead-unwind.rs:+4:9: +4:16
11     let mut _8: Foo;                     // in scope 0 at $DIR/generator-storage-dead-unwind.rs:+4:14: +4:15
12     let _9: ();                          // in scope 0 at $DIR/generator-storage-dead-unwind.rs:+5:9: +5:16
13     let mut _10: Bar;                    // in scope 0 at $DIR/generator-storage-dead-unwind.rs:+5:14: +5:15
14     scope 1 {
15         debug a => _3;                   // in scope 1 at $DIR/generator-storage-dead-unwind.rs:+1:13: +1:14
16         let _4: Bar;                     // in scope 1 at $DIR/generator-storage-dead-unwind.rs:+2:13: +2:14
17         scope 2 {
18             debug b => _4;               // in scope 2 at $DIR/generator-storage-dead-unwind.rs:+2:13: +2:14
19         }
20     }
21
22     bb0: {
23         StorageLive(_3);                 // scope 0 at $DIR/generator-storage-dead-unwind.rs:+1:13: +1:14
24         Deinit(_3);                      // scope 0 at $DIR/generator-storage-dead-unwind.rs:+1:17: +1:23
25         (_3.0: i32) = const 5_i32;       // scope 0 at $DIR/generator-storage-dead-unwind.rs:+1:17: +1:23
26         StorageLive(_4);                 // scope 1 at $DIR/generator-storage-dead-unwind.rs:+2:13: +2:14
27         Deinit(_4);                      // scope 1 at $DIR/generator-storage-dead-unwind.rs:+2:17: +2:23
28         (_4.0: i32) = const 6_i32;       // scope 1 at $DIR/generator-storage-dead-unwind.rs:+2:17: +2:23
29         StorageLive(_5);                 // scope 2 at $DIR/generator-storage-dead-unwind.rs:+3:9: +3:14
30         StorageLive(_6);                 // scope 2 at $DIR/generator-storage-dead-unwind.rs:+3:9: +3:14
31         Deinit(_6);                      // scope 2 at $DIR/generator-storage-dead-unwind.rs:+3:9: +3:14
32         _5 = yield(move _6) -> [resume: bb1, drop: bb5]; // scope 2 at $DIR/generator-storage-dead-unwind.rs:+3:9: +3:14
33     }
34
35     bb1: {
36         StorageDead(_6);                 // scope 2 at $DIR/generator-storage-dead-unwind.rs:+3:13: +3:14
37         StorageDead(_5);                 // scope 2 at $DIR/generator-storage-dead-unwind.rs:+3:14: +3:15
38         StorageLive(_7);                 // scope 2 at $DIR/generator-storage-dead-unwind.rs:+4:9: +4:16
39         StorageLive(_8);                 // scope 2 at $DIR/generator-storage-dead-unwind.rs:+4:14: +4:15
40         _8 = move _3;                    // scope 2 at $DIR/generator-storage-dead-unwind.rs:+4:14: +4:15
41         _7 = take::<Foo>(move _8) -> [return: bb2, unwind: bb9]; // scope 2 at $DIR/generator-storage-dead-unwind.rs:+4:9: +4:16
42                                          // mir::Constant
43                                          // + span: $DIR/generator-storage-dead-unwind.rs:26:9: 26:13
44                                          // + literal: Const { ty: fn(Foo) {take::<Foo>}, val: Value(<ZST>) }
45     }
46
47     bb2: {
48         StorageDead(_8);                 // scope 2 at $DIR/generator-storage-dead-unwind.rs:+4:15: +4:16
49         StorageDead(_7);                 // scope 2 at $DIR/generator-storage-dead-unwind.rs:+4:16: +4:17
50         StorageLive(_9);                 // scope 2 at $DIR/generator-storage-dead-unwind.rs:+5:9: +5:16
51         StorageLive(_10);                // scope 2 at $DIR/generator-storage-dead-unwind.rs:+5:14: +5:15
52         _10 = move _4;                   // scope 2 at $DIR/generator-storage-dead-unwind.rs:+5:14: +5:15
53         _9 = take::<Bar>(move _10) -> [return: bb3, unwind: bb8]; // scope 2 at $DIR/generator-storage-dead-unwind.rs:+5:9: +5:16
54                                          // mir::Constant
55                                          // + span: $DIR/generator-storage-dead-unwind.rs:27:9: 27:13
56                                          // + literal: Const { ty: fn(Bar) {take::<Bar>}, val: Value(<ZST>) }
57     }
58
59     bb3: {
60         StorageDead(_10);                // scope 2 at $DIR/generator-storage-dead-unwind.rs:+5:15: +5:16
61         StorageDead(_9);                 // scope 2 at $DIR/generator-storage-dead-unwind.rs:+5:16: +5:17
62         _0 = const ();                   // scope 0 at $DIR/generator-storage-dead-unwind.rs:+0:19: +6:6
63         StorageDead(_4);                 // scope 1 at $DIR/generator-storage-dead-unwind.rs:+6:5: +6:6
64         StorageDead(_3);                 // scope 0 at $DIR/generator-storage-dead-unwind.rs:+6:5: +6:6
65         drop(_1) -> [return: bb4, unwind: bb11]; // scope 0 at $DIR/generator-storage-dead-unwind.rs:+6:5: +6:6
66     }
67
68     bb4: {
69         return;                          // scope 0 at $DIR/generator-storage-dead-unwind.rs:+0:18: +0:18
70     }
71
72     bb5: {
73         StorageDead(_6);                 // scope 2 at $DIR/generator-storage-dead-unwind.rs:+3:13: +3:14
74         StorageDead(_5);                 // scope 2 at $DIR/generator-storage-dead-unwind.rs:+3:14: +3:15
75         StorageDead(_4);                 // scope 1 at $DIR/generator-storage-dead-unwind.rs:+6:5: +6:6
76         drop(_3) -> [return: bb6, unwind: bb12]; // scope 0 at $DIR/generator-storage-dead-unwind.rs:+6:5: +6:6
77     }
78
79     bb6: {
80         StorageDead(_3);                 // scope 0 at $DIR/generator-storage-dead-unwind.rs:+6:5: +6:6
81         drop(_1) -> [return: bb7, unwind: bb11]; // scope 0 at $DIR/generator-storage-dead-unwind.rs:+6:5: +6:6
82     }
83
84     bb7: {
85         generator_drop;                  // scope 0 at $DIR/generator-storage-dead-unwind.rs:+0:16: +0:18
86     }
87
88     bb8 (cleanup): {
89         StorageDead(_10);                // scope 2 at $DIR/generator-storage-dead-unwind.rs:+5:15: +5:16
90         StorageDead(_9);                 // scope 2 at $DIR/generator-storage-dead-unwind.rs:+5:16: +5:17
91         goto -> bb10;                    // scope 2 at no-location
92     }
93
94     bb9 (cleanup): {
95         StorageDead(_8);                 // scope 2 at $DIR/generator-storage-dead-unwind.rs:+4:15: +4:16
96         StorageDead(_7);                 // scope 2 at $DIR/generator-storage-dead-unwind.rs:+4:16: +4:17
97         goto -> bb10;                    // scope 2 at no-location
98     }
99
100     bb10 (cleanup): {
101         StorageDead(_4);                 // scope 1 at $DIR/generator-storage-dead-unwind.rs:+6:5: +6:6
102         StorageDead(_3);                 // scope 0 at $DIR/generator-storage-dead-unwind.rs:+6:5: +6:6
103         drop(_1) -> bb11;                // scope 0 at $DIR/generator-storage-dead-unwind.rs:+6:5: +6:6
104     }
105
106     bb11 (cleanup): {
107         resume;                          // scope 0 at $DIR/generator-storage-dead-unwind.rs:+0:16: +0:18
108     }
109
110     bb12 (cleanup): {
111         StorageDead(_3);                 // scope 0 at $DIR/generator-storage-dead-unwind.rs:+6:5: +6:6
112         drop(_1) -> bb11;                // scope 0 at $DIR/generator-storage-dead-unwind.rs:+6:5: +6:6
113     }
114 }