Source code

Revision control

Copy as Markdown

Other Tools

use pin_project::pin_project;
// #[repr(packed)] cannot be apply on enums and will be rejected by rustc.
// However, we should not rely on the behavior of rustc that rejects this.
#[repr(packed)] //~ ERROR E0517
enum E1 {
V(()),
}
#[pin_project]
#[repr(packed)] //~ ERROR E0517
enum E2 {
V(()),
}
#[repr(packed)] //~ ERROR E0517
#[pin_project]
enum E3 {
V(()),
}
fn main() {}