summaryrefslogtreecommitdiffstats
path: root/tests/ui/or-patterns/issue-68785-irrefutable-param-with-at.rs
blob: 7339a7e23f9e2111dce4d8bb5347b3d8c1885d5d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
// check-pass

enum MyEnum {
    FirstCase(u8),
    OtherCase(u16),
}

fn my_fn(x @ (MyEnum::FirstCase(_) | MyEnum::OtherCase(_)): MyEnum) {}

fn main() {
    my_fn(MyEnum::FirstCase(0));
}