summary refs log tree commit diff
path: root/src/test/ui/issues/issue-26251.rs
blob: edb06fea8ad5333db9322141654ee1cbd24ca6e5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
// run-pass
#![allow(overlapping_patterns)]

fn main() {
    let x = 'a';

    let y = match x {
        'a'..='b' if false => "one",
        'a' => "two",
        'a'..='b' => "three",
        _ => panic!("what?"),
    };

    assert_eq!(y, "two");
}