summary refs log tree commit diff
path: root/src/test/ui/issues/issue-27033.rs
blob: 2798e510904078fc7f3bb727a862bed8e8695184 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
// FIXME: missing sysroot spans (#53081)
// ignore-i586-unknown-linux-gnu
// ignore-i586-unknown-linux-musl
// ignore-i686-unknown-linux-musl
fn main() {
    match Some(1) {
        None @ _ => {} //~ ERROR match bindings cannot shadow unit variants
    };
    const C: u8 = 1;
    match 1 {
        C @ 2 => { //~ ERROR match bindings cannot shadow constant
            println!("{}", C);
        }
        _ => {}
    };
}