1 // Checks that const expressions have a useful note explaining why they can't be evaluated.
2 // The note should relate to the fact that it cannot be shown forall N that it maps 1-1 to a new
6 #![cfg_attr(full, feature(const_generics))]
7 #![cfg_attr(full, allow(incomplete_features))]
8 #![cfg_attr(min, feature(min_const_generics))]
10 struct Collatz<const N: Option<usize>>;
12 impl <const N: usize> Collatz<{Some(N)}> {}
13 //~^ ERROR the const parameter
14 //[min]~^^ generic parameters must not be used inside of non-trivial constant values
18 impl<const N: usize> Foo {}
19 //~^ ERROR the const parameter