rust/src/test/ui/error-codes/E0517.stderr

37 lines
982 B
Plaintext
Raw Normal View History

2018-02-07 21:35:35 -06:00
error[E0517]: attribute should be applied to struct, enum or union
--> $DIR/E0517.rs:11:8
|
2018-02-22 18:42:32 -06:00
LL | #[repr(C)] //~ ERROR: E0517
2018-02-07 21:35:35 -06:00
| ^
2018-02-22 18:42:32 -06:00
LL | type Foo = u8;
2018-02-07 21:35:35 -06:00
| -------------- not a struct, enum or union
error[E0517]: attribute should be applied to struct or union
--> $DIR/E0517.rs:14:8
|
2018-02-22 18:42:32 -06:00
LL | #[repr(packed)] //~ ERROR: E0517
2018-02-07 21:35:35 -06:00
| ^^^^^^
2018-02-22 18:42:32 -06:00
LL | enum Foo2 {Bar, Baz}
2018-02-07 21:35:35 -06:00
| -------------------- not a struct or union
error[E0517]: attribute should be applied to enum
--> $DIR/E0517.rs:17:8
|
2018-02-22 18:42:32 -06:00
LL | #[repr(u8)] //~ ERROR: E0517
2018-02-07 21:35:35 -06:00
| ^^
2018-02-22 18:42:32 -06:00
LL | struct Foo3 {bar: bool, baz: bool}
2018-02-07 21:35:35 -06:00
| ---------------------------------- not an enum
error[E0517]: attribute should be applied to struct, enum or union
--> $DIR/E0517.rs:20:8
|
2018-02-22 18:42:32 -06:00
LL | #[repr(C)] //~ ERROR: E0517
2018-02-07 21:35:35 -06:00
| ^
2018-02-22 18:42:32 -06:00
LL | / impl Foo3 {
LL | | }
2018-02-07 21:35:35 -06:00
| |_- not a struct, enum or union
error: aborting due to 4 previous errors
2018-03-03 08:59:40 -06:00
For more information about this error, try `rustc --explain E0517`.