summary refs log tree commit diff
path: root/src/test/ui/const-generics/const-param-before-other-params.stderr
blob: 9b18b8c79edda7b50a79597c7a2ca3f3c0f950ca (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
error: lifetime parameters must be declared prior to const parameters
  --> $DIR/const-param-before-other-params.rs:4:21
   |
LL | fn bar<const X: (), 'a>(_: &'a ()) {
   |       --------------^^- help: reorder the parameters: lifetimes, then types, then consts: `<'a, const X: ()>`

error: type parameters must be declared prior to const parameters
  --> $DIR/const-param-before-other-params.rs:8:21
   |
LL | fn foo<const X: (), T>(_: &T) {
   |       --------------^- help: reorder the parameters: lifetimes, then types, then consts: `<T, const X: ()>`

error: aborting due to 2 previous errors