]> git.lizzy.rs Git - rust.git/blob - src/test/ui/const-generics/const-param-before-other-params.rs
Move generic error message to separate branches
[rust.git] / src / test / ui / const-generics / const-param-before-other-params.rs
1 // revisions: full min
2 #![cfg_attr(full, feature(const_generics_defaults))]
3 #![cfg_attr(full, allow(incomplete_features))]
4
5 fn bar<const X: u8, 'a>(_: &'a ()) {
6     //~^ ERROR lifetime parameters must be declared prior to const parameters
7 }
8
9 fn foo<const X: u8, T>(_: &T) {}
10 //[min]~^ ERROR type parameters must be declared prior to const parameters
11
12 fn main() {}