blob: 39d0462616873bfe72bfc34516a1bf92dbdb40f5 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
|
error: suffixed literals are not allowed in attributes
--> $DIR/invalid-rustc_args_required_const-arguments.rs:18:29
|
LL | #[rustc_args_required_const(0usize)]
| ^^^^^^
|
= help: instead of using a suffixed literal (`1u8`, `1.0f32`, etc.), use an unsuffixed version (`1`, `1.0`, etc.)
error: index exceeds number of arguments
--> $DIR/invalid-rustc_args_required_const-arguments.rs:3:29
|
LL | #[rustc_args_required_const(0)]
| ^ there are only 0 arguments
error: index exceeds number of arguments
--> $DIR/invalid-rustc_args_required_const-arguments.rs:6:29
|
LL | #[rustc_args_required_const(1)]
| ^ there is only 1 argument
error: arguments should be non-negative integers
--> $DIR/invalid-rustc_args_required_const-arguments.rs:9:29
|
LL | #[rustc_args_required_const(a)]
| ^
error: arguments should be non-negative integers
--> $DIR/invalid-rustc_args_required_const-arguments.rs:12:32
|
LL | #[rustc_args_required_const(1, a, 2, b)]
| ^ ^
error: attribute should be applied to a function
--> $DIR/invalid-rustc_args_required_const-arguments.rs:15:1
|
LL | #[rustc_args_required_const(0)]
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
LL | struct S;
| --------- not a function
error: index exceeds number of arguments
--> $DIR/invalid-rustc_args_required_const-arguments.rs:22:33
|
LL | #[rustc_args_required_const(1)]
| ^ there is only 1 argument
error: aborting due to 7 previous errors
|