|
1 | | -error: expected unsuffixed literal, found `-` |
2 | | - --> $DIR/malformed-fn-align.rs:29:15 |
3 | | - | |
4 | | -LL | #[rustc_align(-1)] |
5 | | - | ^ |
6 | | - |
7 | | -error: suffixed literals are not allowed in attributes |
8 | | - --> $DIR/malformed-fn-align.rs:35:15 |
9 | | - | |
10 | | -LL | #[rustc_align(4usize)] |
11 | | - | ^^^^^^ |
12 | | - | |
13 | | - = help: instead of using a suffixed literal (`1u8`, `1.0f32`, etc.), use an unsuffixed version (`1`, `1.0`, etc.) |
14 | | - |
15 | 1 | error[E0539]: malformed `rustc_align` attribute input
|
16 | 2 | --> $DIR/malformed-fn-align.rs:10:5
|
17 | 3 | |
|
@@ -51,12 +37,32 @@ error[E0589]: invalid alignment value: not a power of two
|
51 | 37 | LL | #[rustc_align(0)]
|
52 | 38 | | ^
|
53 | 39 |
|
| 40 | +error: expected a literal (`1u8`, `1.0f32`, `"string"`, etc.) here, found `-` |
| 41 | + --> $DIR/malformed-fn-align.rs:29:15 |
| 42 | + | |
| 43 | +LL | #[rustc_align(-1)] |
| 44 | + | ^ |
| 45 | + | |
| 46 | +help: negative numbers are not literals, try removing the `-` sign |
| 47 | + | |
| 48 | +LL - #[rustc_align(-1)] |
| 49 | +LL + #[rustc_align(1)] |
| 50 | + | |
| 51 | + |
54 | 52 | error[E0589]: invalid alignment value: not a power of two
|
55 | 53 | --> $DIR/malformed-fn-align.rs:32:15
|
56 | 54 | |
|
57 | 55 | LL | #[rustc_align(3)]
|
58 | 56 | | ^
|
59 | 57 |
|
| 58 | +error: suffixed literals are not allowed in attributes |
| 59 | + --> $DIR/malformed-fn-align.rs:35:15 |
| 60 | + | |
| 61 | +LL | #[rustc_align(4usize)] |
| 62 | + | ^^^^^^ |
| 63 | + | |
| 64 | + = help: instead of using a suffixed literal (`1u8`, `1.0f32`, etc.), use an unsuffixed version (`1`, `1.0`, etc.) |
| 65 | + |
60 | 66 | error[E0589]: invalid alignment value: not an unsuffixed integer
|
61 | 67 | --> $DIR/malformed-fn-align.rs:35:15
|
62 | 68 | |
|
|
0 commit comments