@@ -7,13 +7,13 @@ LL | #[rustc_legacy_const_generics(0usize)]
7
7
= help: instead of using a suffixed literal (`1u8`, `1.0f32`, etc.), use an unsuffixed version (`1`, `1.0`, etc.)
8
8
9
9
error: malformed `rustc_legacy_const_generics` attribute input
10
- --> $DIR/invalid-rustc_legacy_const_generics-arguments.rs:29 :1
10
+ --> $DIR/invalid-rustc_legacy_const_generics-arguments.rs:32 :1
11
11
|
12
12
LL | #[rustc_legacy_const_generics]
13
13
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: must be of the form: `#[rustc_legacy_const_generics(N)]`
14
14
15
15
error: malformed `rustc_legacy_const_generics` attribute input
16
- --> $DIR/invalid-rustc_legacy_const_generics-arguments.rs:32 :1
16
+ --> $DIR/invalid-rustc_legacy_const_generics-arguments.rs:35 :1
17
17
|
18
18
LL | #[rustc_legacy_const_generics = 1]
19
19
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: must be of the form: `#[rustc_legacy_const_generics(N)]`
@@ -56,11 +56,19 @@ LL | #[rustc_legacy_const_generics(0)]
56
56
LL | struct S;
57
57
| --------- not a function
58
58
59
+ error: #[rustc_legacy_const_generics] functions must only have const generics
60
+ --> $DIR/invalid-rustc_legacy_const_generics-arguments.rs:29:31
61
+ |
62
+ LL | #[rustc_legacy_const_generics(0)]
63
+ | ^
64
+ LL | fn foo8<X>() {}
65
+ | - non-const generic parameter
66
+
59
67
error: index exceeds number of arguments
60
68
--> $DIR/invalid-rustc_legacy_const_generics-arguments.rs:25:35
61
69
|
62
70
LL | #[rustc_legacy_const_generics(1)]
63
71
| ^ there is only 1 argument
64
72
65
- error: aborting due to 10 previous errors
73
+ error: aborting due to 11 previous errors
66
74
0 commit comments