]> git.lizzy.rs Git - rust.git/blob - src/test/ui/attr-usage-repr.stderr
Rollup merge of #53317 - estebank:abolish-ice, r=oli-obk
[rust.git] / src / test / ui / attr-usage-repr.stderr
1 error[E0517]: attribute should be applied to struct, enum or union
2   --> $DIR/attr-usage-repr.rs:14:8
3    |
4 LL | #[repr(C)] //~ ERROR: attribute should be applied to struct, enum or union
5    |        ^
6 LL | fn f() {}
7    | --------- not a struct, enum or union
8
9 error[E0517]: attribute should be applied to enum
10   --> $DIR/attr-usage-repr.rs:26:8
11    |
12 LL | #[repr(i8)] //~ ERROR: attribute should be applied to enum
13    |        ^^
14 LL | struct SInt(f64, f64);
15    | ---------------------- not an enum
16
17 error[E0517]: attribute should be applied to struct or union
18   --> $DIR/attr-usage-repr.rs:32:8
19    |
20 LL | #[repr(align(8))] //~ ERROR: attribute should be applied to struct
21    |        ^^^^^^^^
22 LL | enum EAlign { A, B }
23    | -------------------- not a struct or union
24
25 error[E0517]: attribute should be applied to struct or union
26   --> $DIR/attr-usage-repr.rs:35:8
27    |
28 LL | #[repr(packed)] //~ ERROR: attribute should be applied to struct
29    |        ^^^^^^
30 LL | enum EPacked { A, B }
31    | --------------------- not a struct or union
32
33 error[E0517]: attribute should be applied to struct
34   --> $DIR/attr-usage-repr.rs:38:8
35    |
36 LL | #[repr(simd)] //~ ERROR: attribute should be applied to struct
37    |        ^^^^
38 LL | enum ESimd { A, B }
39    | ------------------- not a struct
40
41 error: aborting due to 5 previous errors
42
43 For more information about this error, try `rustc --explain E0517`.