blob: 69cf8404da18e34506019ef421193e7134bfbbf2 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
|
#![deny(unreachable_patterns)]
#[derive(PartialEq)]
struct Opaque(i32);
impl Eq for Opaque {}
const FOO: Opaque = Opaque(42);
fn main() {
match FOO {
FOO => {},
//~^ ERROR must be annotated with `#[derive(PartialEq, Eq)]`
_ => {}
//~^ ERROR unreachable pattern
}
}
|