aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/rust/execute/xfail/match-identifierpattern-enum.rs
blob: c3a0f65fe710520a7a7be5ed4b639d01cfe0ec20 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
enum Foo {
    I(i32),
}

fn main() -> i32 {
    let x = Foo::I(0);
    let ret = 1;

    match x {
        _ @ Foo::I(b) => { ret = b },
        _ => {},
    };

    ret
}