]> git.lizzy.rs Git - rust.git/blob - src/test/mir-opt/issue_41110.main.ElaborateDrops.after.mir
Auto merge of #80746 - ehuss:update-cargo, r=ehuss
[rust.git] / src / test / mir-opt / issue_41110.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-41110.rs:7:11: 7:11
5     let _1: ();                          // in scope 0 at $DIR/issue-41110.rs:8:9: 8:10
6     let mut _2: S;                       // in scope 0 at $DIR/issue-41110.rs:8:13: 8:14
7     let mut _3: S;                       // in scope 0 at $DIR/issue-41110.rs:8:21: 8:27
8     let mut _4: S;                       // in scope 0 at $DIR/issue-41110.rs:8:21: 8:22
9     scope 1 {
10         debug x => _1;                   // in scope 1 at $DIR/issue-41110.rs:8:9: 8:10
11     }
12
13     bb0: {
14         StorageLive(_1);                 // scope 0 at $DIR/issue-41110.rs:8:9: 8:10
15         StorageLive(_2);                 // scope 0 at $DIR/issue-41110.rs:8:13: 8:14
16         _2 = S;                          // scope 0 at $DIR/issue-41110.rs:8:13: 8:14
17         StorageLive(_3);                 // scope 0 at $DIR/issue-41110.rs:8:21: 8:27
18         StorageLive(_4);                 // scope 0 at $DIR/issue-41110.rs:8:21: 8:22
19         _4 = S;                          // scope 0 at $DIR/issue-41110.rs:8:21: 8:22
20         _3 = S::id(move _4) -> [return: bb1, unwind: bb3]; // scope 0 at $DIR/issue-41110.rs:8:21: 8:27
21                                          // mir::Constant
22                                          // + span: $DIR/issue-41110.rs:8:23: 8:25
23                                          // + literal: Const { ty: fn(S) -> S {S::id}, val: Value(Scalar(<ZST>)) }
24     }
25
26     bb1: {
27         StorageDead(_4);                 // scope 0 at $DIR/issue-41110.rs:8:26: 8:27
28         _1 = S::other(move _2, move _3) -> bb2; // scope 0 at $DIR/issue-41110.rs:8:13: 8:28
29                                          // mir::Constant
30                                          // + span: $DIR/issue-41110.rs:8:15: 8:20
31                                          // + literal: Const { ty: fn(S, S) {S::other}, val: Value(Scalar(<ZST>)) }
32     }
33
34     bb2: {
35         StorageDead(_3);                 // scope 0 at $DIR/issue-41110.rs:8:27: 8:28
36         StorageDead(_2);                 // scope 0 at $DIR/issue-41110.rs:8:27: 8:28
37         _0 = const ();                   // scope 0 at $DIR/issue-41110.rs:7:11: 9:2
38         StorageDead(_1);                 // scope 0 at $DIR/issue-41110.rs:9:1: 9:2
39         return;                          // scope 0 at $DIR/issue-41110.rs:9:2: 9:2
40     }
41
42     bb3 (cleanup): {
43         drop(_2) -> bb4;                 // scope 0 at $DIR/issue-41110.rs:8:27: 8:28
44     }
45
46     bb4 (cleanup): {
47         resume;                          // scope 0 at $DIR/issue-41110.rs:7:1: 9:2
48     }
49 }