summaryrefslogtreecommitdiffstats
path: root/src/test/ui/consts/match_ice.rs
blob: 632335c841e3a51239a5f7662468d0de78a00b02 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
// https://github.com/rust-lang/rust/issues/53708

struct S;

#[derive(PartialEq, Eq)]
struct T;

fn main() {
    const C: &S = &S;
    match C {
        C => {}
        //~^ ERROR must be annotated with `#[derive(PartialEq, Eq)]`
    }
    const K: &T = &T;
    match K {
        K => {}
    }
}