]> git.lizzy.rs Git - rust.git/blob - src/test/mir-opt/issue_41888.main.ElaborateDrops.after.mir
Auto merge of #77476 - tgnottingham:buffered_siphasher128, r=nnethercote
[rust.git] / src / test / mir-opt / issue_41888.main.ElaborateDrops.after.mir
1 // MIR for `main` after ElaborateDrops
2
3 fn main() -> () {
4     let mut _0: ();                      // return place in scope 0 at $DIR/issue-41888.rs:6:11: 6:11
5     let _1: E;                           // in scope 0 at $DIR/issue-41888.rs:7:9: 7:10
6     let mut _2: bool;                    // in scope 0 at $DIR/issue-41888.rs:8:8: 8:14
7     let mut _3: E;                       // in scope 0 at $DIR/issue-41888.rs:9:13: 9:20
8     let mut _4: K;                       // in scope 0 at $DIR/issue-41888.rs:9:18: 9:19
9     let mut _5: isize;                   // in scope 0 at $DIR/issue-41888.rs:10:16: 10:24
10     let mut _7: bool;                    // in scope 0 at $DIR/issue-41888.rs:15:1: 15:2
11     let mut _8: bool;                    // in scope 0 at $DIR/issue-41888.rs:15:1: 15:2
12     let mut _9: bool;                    // in scope 0 at $DIR/issue-41888.rs:15:1: 15:2
13     let mut _10: isize;                  // in scope 0 at $DIR/issue-41888.rs:15:1: 15:2
14     let mut _11: isize;                  // in scope 0 at $DIR/issue-41888.rs:15:1: 15:2
15     scope 1 {
16         debug e => _1;                   // in scope 1 at $DIR/issue-41888.rs:7:9: 7:10
17         let _6: K;                       // in scope 1 at $DIR/issue-41888.rs:10:21: 10:23
18         scope 2 {
19             debug _k => _6;              // in scope 2 at $DIR/issue-41888.rs:10:21: 10:23
20         }
21     }
22
23     bb0: {
24         _9 = const false;                // scope 0 at $DIR/issue-41888.rs:7:9: 7:10
25         _7 = const false;                // scope 0 at $DIR/issue-41888.rs:7:9: 7:10
26         _8 = const false;                // scope 0 at $DIR/issue-41888.rs:7:9: 7:10
27         StorageLive(_1);                 // scope 0 at $DIR/issue-41888.rs:7:9: 7:10
28         StorageLive(_2);                 // scope 1 at $DIR/issue-41888.rs:8:8: 8:14
29         _2 = cond() -> [return: bb1, unwind: bb11]; // scope 1 at $DIR/issue-41888.rs:8:8: 8:14
30                                          // mir::Constant
31                                          // + span: $DIR/issue-41888.rs:8:8: 8:12
32                                          // + literal: Const { ty: fn() -> bool {cond}, val: Value(Scalar(<ZST>)) }
33     }
34
35     bb1: {
36         switchInt(_2) -> [false: bb2, otherwise: bb3]; // scope 1 at $DIR/issue-41888.rs:8:5: 14:6
37     }
38
39     bb2: {
40         _0 = const ();                   // scope 1 at $DIR/issue-41888.rs:8:5: 14:6
41         goto -> bb8;                     // scope 1 at $DIR/issue-41888.rs:8:5: 14:6
42     }
43
44     bb3: {
45         StorageLive(_3);                 // scope 1 at $DIR/issue-41888.rs:9:13: 9:20
46         StorageLive(_4);                 // scope 1 at $DIR/issue-41888.rs:9:18: 9:19
47         _4 = K;                          // scope 1 at $DIR/issue-41888.rs:9:18: 9:19
48         _3 = E::F(move _4);              // scope 1 at $DIR/issue-41888.rs:9:13: 9:20
49         StorageDead(_4);                 // scope 1 at $DIR/issue-41888.rs:9:19: 9:20
50         goto -> bb14;                    // scope 1 at $DIR/issue-41888.rs:9:9: 9:10
51     }
52
53     bb4: {
54         goto -> bb5;                     // scope 1 at $DIR/issue-41888.rs:9:19: 9:20
55     }
56
57     bb5: {
58         StorageDead(_3);                 // scope 1 at $DIR/issue-41888.rs:9:19: 9:20
59         _5 = discriminant(_1);           // scope 1 at $DIR/issue-41888.rs:10:16: 10:24
60         switchInt(move _5) -> [0_isize: bb7, otherwise: bb6]; // scope 1 at $DIR/issue-41888.rs:10:16: 10:24
61     }
62
63     bb6: {
64         _0 = const ();                   // scope 1 at $DIR/issue-41888.rs:10:9: 13:10
65         goto -> bb8;                     // scope 1 at $DIR/issue-41888.rs:10:9: 13:10
66     }
67
68     bb7: {
69         StorageLive(_6);                 // scope 1 at $DIR/issue-41888.rs:10:21: 10:23
70         _9 = const false;                // scope 1 at $DIR/issue-41888.rs:10:21: 10:23
71         _6 = move ((_1 as F).0: K);      // scope 1 at $DIR/issue-41888.rs:10:21: 10:23
72         _0 = const ();                   // scope 2 at $DIR/issue-41888.rs:10:29: 13:10
73         StorageDead(_6);                 // scope 1 at $DIR/issue-41888.rs:13:9: 13:10
74         goto -> bb8;                     // scope 1 at $DIR/issue-41888.rs:10:9: 13:10
75     }
76
77     bb8: {
78         goto -> bb20;                    // scope 0 at $DIR/issue-41888.rs:15:1: 15:2
79     }
80
81     bb9: {
82         _7 = const false;                // scope 0 at $DIR/issue-41888.rs:15:1: 15:2
83         _8 = const false;                // scope 0 at $DIR/issue-41888.rs:15:1: 15:2
84         _9 = const false;                // scope 0 at $DIR/issue-41888.rs:15:1: 15:2
85         StorageDead(_1);                 // scope 0 at $DIR/issue-41888.rs:15:1: 15:2
86         StorageDead(_2);                 // scope 0 at $DIR/issue-41888.rs:15:1: 15:2
87         return;                          // scope 0 at $DIR/issue-41888.rs:15:2: 15:2
88     }
89
90     bb10 (cleanup): {
91         goto -> bb11;                    // scope 1 at $DIR/issue-41888.rs:9:19: 9:20
92     }
93
94     bb11 (cleanup): {
95         goto -> bb12;                    // scope 0 at $DIR/issue-41888.rs:15:1: 15:2
96     }
97
98     bb12 (cleanup): {
99         resume;                          // scope 0 at $DIR/issue-41888.rs:6:1: 15:2
100     }
101
102     bb13 (cleanup): {
103         _7 = const true;                 // scope 1 at $DIR/issue-41888.rs:9:9: 9:10
104         _8 = const true;                 // scope 1 at $DIR/issue-41888.rs:9:9: 9:10
105         _9 = const true;                 // scope 1 at $DIR/issue-41888.rs:9:9: 9:10
106         _1 = move _3;                    // scope 1 at $DIR/issue-41888.rs:9:9: 9:10
107         goto -> bb10;                    // scope 1 at $DIR/issue-41888.rs:9:9: 9:10
108     }
109
110     bb14: {
111         _7 = const true;                 // scope 1 at $DIR/issue-41888.rs:9:9: 9:10
112         _8 = const true;                 // scope 1 at $DIR/issue-41888.rs:9:9: 9:10
113         _9 = const true;                 // scope 1 at $DIR/issue-41888.rs:9:9: 9:10
114         _1 = move _3;                    // scope 1 at $DIR/issue-41888.rs:9:9: 9:10
115         goto -> bb4;                     // scope 1 at $DIR/issue-41888.rs:9:9: 9:10
116     }
117
118     bb15: {
119         _7 = const false;                // scope 0 at $DIR/issue-41888.rs:15:1: 15:2
120         goto -> bb9;                     // scope 0 at $DIR/issue-41888.rs:15:1: 15:2
121     }
122
123     bb16 (cleanup): {
124         goto -> bb12;                    // scope 0 at $DIR/issue-41888.rs:15:1: 15:2
125     }
126
127     bb17: {
128         drop(_1) -> [return: bb15, unwind: bb12]; // scope 0 at $DIR/issue-41888.rs:15:1: 15:2
129     }
130
131     bb18 (cleanup): {
132         drop(_1) -> bb12;                // scope 0 at $DIR/issue-41888.rs:15:1: 15:2
133     }
134
135     bb19: {
136         _10 = discriminant(_1);          // scope 0 at $DIR/issue-41888.rs:15:1: 15:2
137         switchInt(move _10) -> [0_isize: bb15, otherwise: bb17]; // scope 0 at $DIR/issue-41888.rs:15:1: 15:2
138     }
139
140     bb20: {
141         switchInt(_7) -> [false: bb15, otherwise: bb19]; // scope 0 at $DIR/issue-41888.rs:15:1: 15:2
142     }
143
144     bb21 (cleanup): {
145         _11 = discriminant(_1);          // scope 0 at $DIR/issue-41888.rs:15:1: 15:2
146         switchInt(move _11) -> [0_isize: bb16, otherwise: bb18]; // scope 0 at $DIR/issue-41888.rs:15:1: 15:2
147     }
148
149     bb22 (cleanup): {
150         switchInt(_7) -> [false: bb12, otherwise: bb21]; // scope 0 at $DIR/issue-41888.rs:15:1: 15:2
151     }
152 }