]> git.lizzy.rs Git - rust.git/blob - src/test/ui/repr/repr-transparent-other-items.stderr
Implement RFC 2645 (transparent enums and unions)
[rust.git] / src / test / ui / repr / repr-transparent-other-items.stderr
1 error[E0517]: attribute should be applied to struct, enum, or union
2   --> $DIR/repr-transparent-other-items.rs:3:8
3    |
4 LL | #[repr(transparent)]
5    |        ^^^^^^^^^^^
6 LL | fn cant_repr_this() {}
7    | ---------------------- not a struct, enum, or union
8
9 error[E0517]: attribute should be applied to struct, enum, or union
10   --> $DIR/repr-transparent-other-items.rs:6:8
11    |
12 LL | #[repr(transparent)]
13    |        ^^^^^^^^^^^
14 LL | static CANT_REPR_THIS: u32 = 0;
15    | ------------------------------- not a struct, enum, or union
16
17 error: aborting due to 2 previous errors
18
19 For more information about this error, try `rustc --explain E0517`.