summaryrefslogtreecommitdiffstats
path: root/tests/mir-opt/building/custom/enums.switch_bool.built.after.mir
blob: 95c57d2dca33a3fd2996dc91fba4fc62231bc221 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
// MIR for `switch_bool` after built

fn switch_bool(_1: bool) -> u32 {
    let mut _0: u32;                     // return place in scope 0 at $DIR/enums.rs:+0:32: +0:35

    bb0: {
        switchInt(_1) -> [1: bb1, 0: bb2, otherwise: bb2]; // scope 0 at $DIR/enums.rs:+3:13: +7:14
    }

    bb1: {
        _0 = const 5_u32;                // scope 0 at $DIR/enums.rs:+11:13: +11:20
        return;                          // scope 0 at $DIR/enums.rs:+12:13: +12:21
    }

    bb2: {
        _0 = const 10_u32;               // scope 0 at $DIR/enums.rs:+16:13: +16:21
        return;                          // scope 0 at $DIR/enums.rs:+17:13: +17:21
    }
}