//@ check-pass // Tests that const patterns that use generic parameters are // allowed if we are still able to evaluate them. trait Trait { const ASSOC: usize; } impl Trait for T { const ASSOC: usize = 10; } fn foo(a: usize) { match a { ::ASSOC => (), _ => (), } } fn main() {}