]> git.proxmox.com Git - rustc.git/blob - tests/ui/rfcs/rfc1445/eq-allows-match.rs
New upstream version 1.68.2+dfsg1
[rustc.git] / tests / ui / rfcs / rfc1445 / eq-allows-match.rs
1 // run-pass
2 #![allow(dead_code)]
3
4 #[derive(PartialEq, Eq)]
5 struct Foo {
6 x: u32
7 }
8
9 const FOO: Foo = Foo { x: 0 };
10
11 fn main() {
12 let y = Foo { x: 1 };
13 match y {
14 FOO => { }
15 _ => { }
16 }
17 }