]> git.proxmox.com Git - rustc.git/blame - src/test/ui/consts/const_in_pattern/cross-crate-pass.rs
Update unsuspicious file list
[rustc.git] / src / test / ui / consts / const_in_pattern / cross-crate-pass.rs
CommitLineData
f9f354fc
XL
1// run-pass
2// aux-build:consts.rs
3
4#![warn(indirect_structural_match)]
5
6extern crate consts;
7use consts::CustomEq;
8
9struct Defaulted;
10impl consts::AssocConst for Defaulted {}
11
12fn main() {
13 let _ = Defaulted;
14 match Some(CustomEq) {
15 consts::NONE => panic!(),
16 _ => {}
17 }
18
19 match Some(CustomEq) {
20 <Defaulted as consts::AssocConst>::NONE => panic!(),
21 _ => {}
22 }
23}