1 // Make sure redundant testing paths in `match` expressions are sorted out.
3 #![feature(exclusive_range_pattern)]
9 // When `(0..=10).contains(x) && !b`, we should jump to the last arm
10 // without testing two other candidates.
20 // START rustc.main.SimplifyCfg-initial.after.mir
23 // _4 = Le(const 0i32, _1);
24 // switchInt(move _4) -> [false: bb10, otherwise: bb11];
43 // falseEdges -> [real: bb12, imaginary: bb6];
46 // falseEdges -> [real: bb2, imaginary: bb7];
49 // falseEdges -> [real: bb3, imaginary: bb8];
52 // falseEdges -> [real: bb4, imaginary: bb9];
58 // _7 = Le(const 10i32, _1);
59 // switchInt(move _7) -> [false: bb14, otherwise: bb15];
62 // _5 = Lt(_1, const 10i32);
63 // switchInt(move _5) -> [false: bb10, otherwise: bb5];
68 // switchInt(move _6) -> [false: bb13, otherwise: bb1];
71 // falseEdges -> [real: bb8, imaginary: bb6];
74 // switchInt(_1) -> [-1i32: bb7, otherwise: bb8];
77 // _8 = Le(_1, const 20i32);
78 // switchInt(move _8) -> [false: bb14, otherwise: bb6];
85 // END rustc.main.SimplifyCfg-initial.after.mir