1 // Regression test for #72819: ICE due to failure in resolving the const generic in `Arr`'s type
4 #![cfg_attr(full, feature(generic_const_exprs))]
5 #![cfg_attr(full, allow(incomplete_features))]
7 struct Arr<const N: usize>
8 where Assert::<{N < usize::MAX / 2}>: IsTrue,
9 //[min]~^ ERROR generic parameters may not be used in const operations
13 enum Assert<const CHECK: bool> {}
17 impl IsTrue for Assert<true> {}
20 let x: Arr<{usize::MAX}> = Arr {};
21 //[full]~^ ERROR mismatched types
22 //[full]~| ERROR mismatched types