fork/rust
git clone https://git.julia.blue/fork/rust
49cae55760d
1.44.0
1// MIR for `main` after SimplifyCfg-elaborate-drops 2 3fn main() -> () { 4 let mut _0: (); // return place in scope 0 at $DIR/packed-struct-drop-aligned.rs:5:11: 5:11 5 let mut _1: Packed; // in scope 0 at $DIR/packed-struct-drop-aligned.rs:6:9: 6:14 6 let mut _2: Aligned; // in scope 0 at $DIR/packed-struct-drop-aligned.rs:6:24: 6:42 7 let mut _3: Droppy; // in scope 0 at $DIR/packed-struct-drop-aligned.rs:6:32: 6:41 8 let mut _4: Aligned; // in scope 0 at $DIR/packed-struct-drop-aligned.rs:7:11: 7:29 9 let mut _5: Droppy; // in scope 0 at $DIR/packed-struct-drop-aligned.rs:7:19: 7:28 10 let mut _6: Aligned; // in scope 0 at $DIR/packed-struct-drop-aligned.rs:7:5: 7:8 11 scope 1 { 12 debug x => _1; // in scope 1 at $DIR/packed-struct-drop-aligned.rs:6:9: 6:14 13 } 14 15 bb0: { 16 StorageLive(_1); // bb0[0]: scope 0 at $DIR/packed-struct-drop-aligned.rs:6:9: 6:14 17 StorageLive(_2); // bb0[1]: scope 0 at $DIR/packed-struct-drop-aligned.rs:6:24: 6:42 18 StorageLive(_3); // bb0[2]: scope 0 at $DIR/packed-struct-drop-aligned.rs:6:32: 6:41 19 _3 = Droppy(const 0usize); // bb0[3]: scope 0 at $DIR/packed-struct-drop-aligned.rs:6:32: 6:41 20 // ty::Const 21 // + ty: usize 22 // + val: Value(Scalar(0x00000000)) 23 // mir::Constant 24 // + span: $DIR/packed-struct-drop-aligned.rs:6:39: 6:40 25 // + literal: Const { ty: usize, val: Value(Scalar(0x00000000)) } 26 _2 = Aligned(move _3); // bb0[4]: scope 0 at $DIR/packed-struct-drop-aligned.rs:6:24: 6:42 27 StorageDead(_3); // bb0[5]: scope 0 at $DIR/packed-struct-drop-aligned.rs:6:41: 6:42 28 _1 = Packed(move _2); // bb0[6]: scope 0 at $DIR/packed-struct-drop-aligned.rs:6:17: 6:43 29 StorageDead(_2); // bb0[7]: scope 0 at $DIR/packed-struct-drop-aligned.rs:6:42: 6:43 30 StorageLive(_4); // bb0[8]: scope 1 at $DIR/packed-struct-drop-aligned.rs:7:11: 7:29 31 StorageLive(_5); // bb0[9]: scope 1 at $DIR/packed-struct-drop-aligned.rs:7:19: 7:28 32 _5 = Droppy(const 0usize); // bb0[10]: scope 1 at $DIR/packed-struct-drop-aligned.rs:7:19: 7:28 33 // ty::Const 34 // + ty: usize 35 // + val: Value(Scalar(0x00000000)) 36 // mir::Constant 37 // + span: $DIR/packed-struct-drop-aligned.rs:7:26: 7:27 38 // + literal: Const { ty: usize, val: Value(Scalar(0x00000000)) } 39 _4 = Aligned(move _5); // bb0[11]: scope 1 at $DIR/packed-struct-drop-aligned.rs:7:11: 7:29 40 StorageDead(_5); // bb0[12]: scope 1 at $DIR/packed-struct-drop-aligned.rs:7:28: 7:29 41 StorageLive(_6); // bb0[13]: scope 1 at $DIR/packed-struct-drop-aligned.rs:7:5: 7:8 42 _6 = move (_1.0: Aligned); // bb0[14]: scope 1 at $DIR/packed-struct-drop-aligned.rs:7:5: 7:8 43 drop(_6) -> [return: bb4, unwind: bb3]; // bb0[15]: scope 1 at $DIR/packed-struct-drop-aligned.rs:7:5: 7:8 44 } 45 46 bb1 (cleanup): { 47 resume; // bb1[0]: scope 0 at $DIR/packed-struct-drop-aligned.rs:5:1: 8:2 48 } 49 50 bb2: { 51 StorageDead(_1); // bb2[0]: scope 0 at $DIR/packed-struct-drop-aligned.rs:8:1: 8:2 52 return; // bb2[1]: scope 0 at $DIR/packed-struct-drop-aligned.rs:8:2: 8:2 53 } 54 55 bb3 (cleanup): { 56 (_1.0: Aligned) = move _4; // bb3[0]: scope 1 at $DIR/packed-struct-drop-aligned.rs:7:5: 7:8 57 drop(_1) -> bb1; // bb3[1]: scope 0 at $DIR/packed-struct-drop-aligned.rs:8:1: 8:2 58 } 59 60 bb4: { 61 StorageDead(_6); // bb4[0]: scope 1 at $DIR/packed-struct-drop-aligned.rs:7:5: 7:8 62 (_1.0: Aligned) = move _4; // bb4[1]: scope 1 at $DIR/packed-struct-drop-aligned.rs:7:5: 7:8 63 StorageDead(_4); // bb4[2]: scope 1 at $DIR/packed-struct-drop-aligned.rs:7:28: 7:29 64 _0 = const (); // bb4[3]: scope 0 at $DIR/packed-struct-drop-aligned.rs:5:11: 8:2 65 // ty::Const 66 // + ty: () 67 // + val: Value(Scalar(<ZST>)) 68 // mir::Constant 69 // + span: $DIR/packed-struct-drop-aligned.rs:5:11: 8:2 70 // + literal: Const { ty: (), val: Value(Scalar(<ZST>)) } 71 drop(_1) -> [return: bb2, unwind: bb1]; // bb4[4]: scope 0 at $DIR/packed-struct-drop-aligned.rs:8:1: 8:2 72 } 73}