fork/rust
git clone https://git.julia.blue/fork/rust
3bcad65fbf6
master
1- // MIR for `main` before Derefer 2+ // MIR for `main` after Derefer 3 4 fn main() -> () { 5 let mut _0: (); 6 let _1: std::boxed::Box<std::boxed::Box<u32>>; 7 let mut _2: std::boxed::Box<u32>; 8 9 bb0: { 10 StorageLive(_1); 11 StorageLive(_2); 12 _2 = f() -> [return: bb1, unwind: bb5]; 13 } 14 15 bb1: { 16 _1 = Box::<Box<u32>>::new(move _2) -> [return: bb2, unwind: bb4]; 17 } 18 19 bb2: { 20 StorageDead(_2); 21 drop(_1) -> [return: bb3, unwind: bb5]; 22 } 23 24 bb3: { 25 StorageDead(_1); 26 _0 = const (); 27 return; 28 } 29 30 bb4 (cleanup): { 31 drop(_2) -> [return: bb5, unwind terminate(cleanup)]; 32 } 33 34 bb5 (cleanup): { 35 resume; 36 } 37 } 38