diff --git a/src/test/ui/feature-gates/feature-gate-const_generics_defaults.rs b/src/test/ui/feature-gates/feature-gate-const_generics_defaults.rs deleted file mode 100644 index 5b5ccc88873..00000000000 --- a/src/test/ui/feature-gates/feature-gate-const_generics_defaults.rs +++ /dev/null @@ -1,9 +0,0 @@ -#[cfg(FALSE)] -struct A; -//~^ ERROR default values for const generic parameters are experimental - -#[cfg(FALSE)] -fn foo() {} -//~^ ERROR default values for const generic parameters are experimental - -fn main() {} diff --git a/src/test/ui/feature-gates/feature-gate-const_generics_defaults.stderr b/src/test/ui/feature-gates/feature-gate-const_generics_defaults.stderr deleted file mode 100644 index e2b48d793fd..00000000000 --- a/src/test/ui/feature-gates/feature-gate-const_generics_defaults.stderr +++ /dev/null @@ -1,21 +0,0 @@ -error[E0658]: default values for const generic parameters are experimental - --> $DIR/feature-gate-const_generics_defaults.rs:2:25 - | -LL | struct A; - | ^^^ - | - = note: see issue #44580 for more information - = help: add `#![feature(const_generics_defaults)]` to the crate attributes to enable - -error[E0658]: default values for const generic parameters are experimental - --> $DIR/feature-gate-const_generics_defaults.rs:6:22 - | -LL | fn foo() {} - | ^^^^^^^ - | - = note: see issue #44580 for more information - = help: add `#![feature(const_generics_defaults)]` to the crate attributes to enable - -error: aborting due to 2 previous errors - -For more information about this error, try `rustc --explain E0658`. diff --git a/src/test/ui/generics/issue-59508-1.stderr b/src/test/ui/generics/issue-59508-1.stderr index df244f02dce..d162365ea4b 100644 --- a/src/test/ui/generics/issue-59508-1.stderr +++ b/src/test/ui/generics/issue-59508-1.stderr @@ -1,5 +1,5 @@ error: lifetime parameters must be declared prior to type parameters - --> $DIR/issue-59508-1.rs:11:25 + --> $DIR/issue-59508-1.rs:10:25 | LL | pub fn do_things() { | ----^^--^^----- help: reorder the parameters: lifetimes, then consts and types: `<'a, 'b: 'a, T>` diff --git a/src/test/ui/generics/issue-59508.stderr b/src/test/ui/generics/issue-59508.stderr index 33e967cebff..c52ae4182b8 100644 --- a/src/test/ui/generics/issue-59508.stderr +++ b/src/test/ui/generics/issue-59508.stderr @@ -2,7 +2,7 @@ error: lifetime parameters must be declared prior to type parameters --> $DIR/issue-59508.rs:10:25 | LL | pub fn do_things() { - | ----^^--^^----- help: reorder the parameters: lifetimes, then types, then consts: `<'a, 'b: 'a, T>` + | ----^^--^^----- help: reorder the parameters: lifetimes, then consts and types: `<'a, 'b: 'a, T>` error: aborting due to previous error diff --git a/src/test/ui/generics/lifetime-before-type-params.stderr b/src/test/ui/generics/lifetime-before-type-params.stderr index 047bc7f6d90..62d95e45329 100644 --- a/src/test/ui/generics/lifetime-before-type-params.stderr +++ b/src/test/ui/generics/lifetime-before-type-params.stderr @@ -2,25 +2,25 @@ error: lifetime parameters must be declared prior to type parameters --> $DIR/lifetime-before-type-params.rs:2:13 | LL | fn first() {} - | ----^^--^^- help: reorder the parameters: lifetimes, then types, then consts: `<'a, 'b, T>` + | ----^^--^^- help: reorder the parameters: lifetimes, then consts and types: `<'a, 'b, T>` error: lifetime parameters must be declared prior to type parameters --> $DIR/lifetime-before-type-params.rs:4:18 | LL | fn second<'a, T, 'b>() {} - | --------^^- help: reorder the parameters: lifetimes, then types, then consts: `<'a, 'b, T>` + | --------^^- help: reorder the parameters: lifetimes, then consts and types: `<'a, 'b, T>` error: lifetime parameters must be declared prior to type parameters --> $DIR/lifetime-before-type-params.rs:6:16 | LL | fn third() {} - | -------^^- help: reorder the parameters: lifetimes, then types, then consts: `<'a, T, U>` + | -------^^- help: reorder the parameters: lifetimes, then consts and types: `<'a, T, U>` error: lifetime parameters must be declared prior to type parameters --> $DIR/lifetime-before-type-params.rs:8:18 | LL | fn fourth<'a, T, 'b, U, 'c, V>() {} - | --------^^-----^^---- help: reorder the parameters: lifetimes, then types, then consts: `<'a, 'b, 'c, T, U, V>` + | --------^^-----^^---- help: reorder the parameters: lifetimes, then consts and types: `<'a, 'b, 'c, T, U, V>` error: aborting due to 4 previous errors diff --git a/src/test/ui/issues/issue-80512-param-reordering-with-defaults.stderr b/src/test/ui/issues/issue-80512-param-reordering-with-defaults.stderr index a1e9a903f81..119b1a0d207 100644 --- a/src/test/ui/issues/issue-80512-param-reordering-with-defaults.stderr +++ b/src/test/ui/issues/issue-80512-param-reordering-with-defaults.stderr @@ -2,7 +2,7 @@ error: lifetime parameters must be declared prior to type parameters --> $DIR/issue-80512-param-reordering-with-defaults.rs:3:18 | LL | struct S(&'a T); - | ---------^^- help: reorder the parameters: lifetimes, then types, then consts: `<'a, T = ()>` + | ---------^^- help: reorder the parameters: lifetimes, then consts and types: `<'a, T = ()>` error: aborting due to previous error diff --git a/src/test/ui/missing/missing-items/missing-type-parameter2.stderr b/src/test/ui/missing/missing-items/missing-type-parameter2.stderr index f955659f23d..3b930d7e4ec 100644 --- a/src/test/ui/missing/missing-items/missing-type-parameter2.stderr +++ b/src/test/ui/missing/missing-items/missing-type-parameter2.stderr @@ -1,5 +1,5 @@ error[E0412]: cannot find type `N` in this scope - --> $DIR/missing-type-parameter2.rs:6:8 + --> $DIR/missing-type-parameter2.rs:3:8 | LL | struct X(); | ------------------------ similarly named struct `X` defined here @@ -17,7 +17,7 @@ LL | impl X {} | +++ error[E0412]: cannot find type `N` in this scope - --> $DIR/missing-type-parameter2.rs:9:28 + --> $DIR/missing-type-parameter2.rs:6:28 | LL | impl X {} | - ^ @@ -34,7 +34,7 @@ LL | impl X {} | +++ error[E0412]: cannot find type `T` in this scope - --> $DIR/missing-type-parameter2.rs:14:20 + --> $DIR/missing-type-parameter2.rs:11:20 | LL | struct X(); | ------------------------ similarly named struct `X` defined here @@ -52,7 +52,7 @@ LL | fn foo(_: T) where T: Send {} | +++ error[E0412]: cannot find type `T` in this scope - --> $DIR/missing-type-parameter2.rs:14:11 + --> $DIR/missing-type-parameter2.rs:11:11 | LL | struct X(); | ------------------------ similarly named struct `X` defined here @@ -70,7 +70,7 @@ LL | fn foo(_: T) where T: Send {} | +++ error[E0412]: cannot find type `A` in this scope - --> $DIR/missing-type-parameter2.rs:18:24 + --> $DIR/missing-type-parameter2.rs:15:24 | LL | struct X(); | ------------------------ similarly named struct `X` defined here @@ -88,7 +88,7 @@ LL | fn bar(_: A) {} | +++ error[E0747]: unresolved item provided when a constant was expected - --> $DIR/missing-type-parameter2.rs:6:8 + --> $DIR/missing-type-parameter2.rs:3:8 | LL | impl X {} | ^ @@ -99,13 +99,13 @@ LL | impl X<{ N }> {} | + + error: defaults for const parameters are only allowed in `struct`, `enum`, `type`, or `trait` definitions - --> $DIR/missing-type-parameter2.rs:9:15 + --> $DIR/missing-type-parameter2.rs:6:15 | LL | impl X {} | ^ error[E0747]: unresolved item provided when a constant was expected - --> $DIR/missing-type-parameter2.rs:9:28 + --> $DIR/missing-type-parameter2.rs:6:28 | LL | impl X {} | ^ diff --git a/src/test/ui/parser/issues/issue-14303-enum.stderr b/src/test/ui/parser/issues/issue-14303-enum.stderr index bcecd75b1ab..55cef4cabac 100644 --- a/src/test/ui/parser/issues/issue-14303-enum.stderr +++ b/src/test/ui/parser/issues/issue-14303-enum.stderr @@ -2,7 +2,7 @@ error: lifetime parameters must be declared prior to type parameters --> $DIR/issue-14303-enum.rs:1:15 | LL | enum X<'a, T, 'b> { - | --------^^- help: reorder the parameters: lifetimes, then types, then consts: `<'a, 'b, T>` + | --------^^- help: reorder the parameters: lifetimes, then consts and types: `<'a, 'b, T>` error: aborting due to previous error diff --git a/src/test/ui/parser/issues/issue-14303-fn-def.stderr b/src/test/ui/parser/issues/issue-14303-fn-def.stderr index 082c37e0be7..bacc922969d 100644 --- a/src/test/ui/parser/issues/issue-14303-fn-def.stderr +++ b/src/test/ui/parser/issues/issue-14303-fn-def.stderr @@ -2,7 +2,7 @@ error: lifetime parameters must be declared prior to type parameters --> $DIR/issue-14303-fn-def.rs:1:15 | LL | fn foo<'a, T, 'b>(x: &'a T) {} - | --------^^- help: reorder the parameters: lifetimes, then types, then consts: `<'a, 'b, T>` + | --------^^- help: reorder the parameters: lifetimes, then consts and types: `<'a, 'b, T>` error: aborting due to previous error diff --git a/src/test/ui/parser/issues/issue-14303-impl.stderr b/src/test/ui/parser/issues/issue-14303-impl.stderr index 3b5615d2a9e..d6be02f70fd 100644 --- a/src/test/ui/parser/issues/issue-14303-impl.stderr +++ b/src/test/ui/parser/issues/issue-14303-impl.stderr @@ -2,7 +2,7 @@ error: lifetime parameters must be declared prior to type parameters --> $DIR/issue-14303-impl.rs:3:13 | LL | impl<'a, T, 'b> X {} - | --------^^- help: reorder the parameters: lifetimes, then types, then consts: `<'a, 'b, T>` + | --------^^- help: reorder the parameters: lifetimes, then consts and types: `<'a, 'b, T>` error: aborting due to previous error diff --git a/src/test/ui/parser/issues/issue-14303-struct.stderr b/src/test/ui/parser/issues/issue-14303-struct.stderr index dbd0b987dd1..fa62a39f241 100644 --- a/src/test/ui/parser/issues/issue-14303-struct.stderr +++ b/src/test/ui/parser/issues/issue-14303-struct.stderr @@ -2,7 +2,7 @@ error: lifetime parameters must be declared prior to type parameters --> $DIR/issue-14303-struct.rs:1:17 | LL | struct X<'a, T, 'b> { - | --------^^- help: reorder the parameters: lifetimes, then types, then consts: `<'a, 'b, T>` + | --------^^- help: reorder the parameters: lifetimes, then consts and types: `<'a, 'b, T>` error: aborting due to previous error diff --git a/src/test/ui/parser/issues/issue-14303-trait.stderr b/src/test/ui/parser/issues/issue-14303-trait.stderr index 7dfa62d823f..75cd67a9ded 100644 --- a/src/test/ui/parser/issues/issue-14303-trait.stderr +++ b/src/test/ui/parser/issues/issue-14303-trait.stderr @@ -2,7 +2,7 @@ error: lifetime parameters must be declared prior to type parameters --> $DIR/issue-14303-trait.rs:1:18 | LL | trait Foo<'a, T, 'b> {} - | --------^^- help: reorder the parameters: lifetimes, then types, then consts: `<'a, 'b, T>` + | --------^^- help: reorder the parameters: lifetimes, then consts and types: `<'a, 'b, T>` error: aborting due to previous error diff --git a/src/test/ui/suggestions/suggest-move-lifetimes.stderr b/src/test/ui/suggestions/suggest-move-lifetimes.stderr index 657914d1c8c..f52631caed1 100644 --- a/src/test/ui/suggestions/suggest-move-lifetimes.stderr +++ b/src/test/ui/suggestions/suggest-move-lifetimes.stderr @@ -2,25 +2,25 @@ error: lifetime parameters must be declared prior to type parameters --> $DIR/suggest-move-lifetimes.rs:1:13 | LL | struct A { - | ----^^- help: reorder the parameters: lifetimes, then types, then consts: `<'a, T>` + | ----^^- help: reorder the parameters: lifetimes, then consts and types: `<'a, T>` error: lifetime parameters must be declared prior to type parameters --> $DIR/suggest-move-lifetimes.rs:5:13 | LL | struct B { - | ----^^---- help: reorder the parameters: lifetimes, then types, then consts: `<'a, T, U>` + | ----^^---- help: reorder the parameters: lifetimes, then consts and types: `<'a, T, U>` error: lifetime parameters must be declared prior to type parameters --> $DIR/suggest-move-lifetimes.rs:10:16 | LL | struct C { - | -------^^- help: reorder the parameters: lifetimes, then types, then consts: `<'a, T, U>` + | -------^^- help: reorder the parameters: lifetimes, then consts and types: `<'a, T, U>` error: lifetime parameters must be declared prior to type parameters --> $DIR/suggest-move-lifetimes.rs:15:16 | LL | struct D { - | -------^^--^^-----^^- help: reorder the parameters: lifetimes, then types, then consts: `<'a, 'b, 'c, T, U, V>` + | -------^^--^^-----^^- help: reorder the parameters: lifetimes, then consts and types: `<'a, 'b, 'c, T, U, V>` error: aborting due to 4 previous errors