fork/rust
git clone https://git.julia.blue/fork/rust
3bcad65fbf6
master
1- // MIR for `f` before ConstGoto 2+ // MIR for `f` after ConstGoto 3 4 fn f() -> u64 { 5 let mut _0: u64; 6 let mut _1: bool; 7 let mut _2: i32; 8 9 bb0: { 10 StorageLive(_1); 11 StorageLive(_2); 12 _2 = const A; 13 switchInt(_2) -> [1: bb2, 2: bb2, 3: bb2, otherwise: bb1]; 14 } 15 16 bb1: { 17 _1 = const true; 18 goto -> bb3; 19 } 20 21 bb2: { 22 _1 = const B; 23- goto -> bb3; 24+ switchInt(_1) -> [0: bb4, otherwise: bb3]; 25 } 26 27 bb3: { 28- switchInt(_1) -> [0: bb5, otherwise: bb4]; 29- } 30- 31- bb4: { 32 _0 = const 2_u64; 33- goto -> bb6; 34+ goto -> bb5; 35 } 36 37- bb5: { 38+ bb4: { 39 _0 = const 1_u64; 40- goto -> bb6; 41+ goto -> bb5; 42 } 43 44- bb6: { 45+ bb5: { 46 StorageDead(_2); 47 StorageDead(_1); 48 return; 49 } 50 } 51