1error[E0793]: reference to packed field is unaligned 2 --> tests/ui/pin_project/packed.rs:5:1 3 | 45 | / pin_project! { //~ ERROR reference to packed field is unaligned 56 | | #[repr(packed, C)] 67 | | struct Packed { 78 | | #[pin] 8... | 911 | | } 10 | |_^ 11 | 12 = note: packed structs are only aligned by one byte, and many modern architectures penalize unaligned field accesses 13 = note: creating a misaligned reference is undefined behavior (even if that reference is never dereferenced) 14 = help: copy the field contents to a local variable, or replace the reference with a raw pointer and use `read_unaligned`/`write_unaligned` (loads and stores via `*p` must be properly aligned even when using raw pointers) 15 = note: this error originates in the macro `$crate::__pin_project_struct_make_proj_method` which comes from the expansion of the macro `pin_project` (in Nightly builds, run with -Z macro-backtrace for more info) 16 17error[E0793]: reference to packed field is unaligned 18 --> tests/ui/pin_project/packed.rs:5:1 19 | 205 | / pin_project! { //~ ERROR reference to packed field is unaligned 216 | | #[repr(packed, C)] 227 | | struct Packed { 238 | | #[pin] 24... | 2511 | | } 26 | |_^ 27 | 28 = note: packed structs are only aligned by one byte, and many modern architectures penalize unaligned field accesses 29 = note: creating a misaligned reference is undefined behavior (even if that reference is never dereferenced) 30 = help: copy the field contents to a local variable, or replace the reference with a raw pointer and use `read_unaligned`/`write_unaligned` (loads and stores via `*p` must be properly aligned even when using raw pointers) 31 = note: this error originates in the macro `$crate::__pin_project_struct_make_proj_method` which comes from the expansion of the macro `pin_project` (in Nightly builds, run with -Z macro-backtrace for more info) 32 33error[E0793]: reference to packed field is unaligned 34 --> tests/ui/pin_project/packed.rs:5:1 35 | 365 | / pin_project! { //~ ERROR reference to packed field is unaligned 376 | | #[repr(packed, C)] 387 | | struct Packed { 398 | | #[pin] 40... | 4111 | | } 42 | |_^ 43 | 44 = note: packed structs are only aligned by one byte, and many modern architectures penalize unaligned field accesses 45 = note: creating a misaligned reference is undefined behavior (even if that reference is never dereferenced) 46 = help: copy the field contents to a local variable, or replace the reference with a raw pointer and use `read_unaligned`/`write_unaligned` (loads and stores via `*p` must be properly aligned even when using raw pointers) 47 = note: this error originates in the macro `$crate::__pin_project_constant` which comes from the expansion of the macro `pin_project` (in Nightly builds, run with -Z macro-backtrace for more info) 48 49error[E0793]: reference to packed field is unaligned 50 --> tests/ui/pin_project/packed.rs:13:1 51 | 5213 | / pin_project! { //~ ERROR reference to packed field is unaligned 5314 | | #[repr(packed(2))] 5415 | | struct PackedN { 5516 | | #[pin] 56... | 5719 | | } 58 | |_^ 59 | 60 = note: packed structs are only aligned by one byte, and many modern architectures penalize unaligned field accesses 61 = note: creating a misaligned reference is undefined behavior (even if that reference is never dereferenced) 62 = help: copy the field contents to a local variable, or replace the reference with a raw pointer and use `read_unaligned`/`write_unaligned` (loads and stores via `*p` must be properly aligned even when using raw pointers) 63 = note: this error originates in the macro `$crate::__pin_project_struct_make_proj_method` which comes from the expansion of the macro `pin_project` (in Nightly builds, run with -Z macro-backtrace for more info) 64 65error[E0793]: reference to packed field is unaligned 66 --> tests/ui/pin_project/packed.rs:13:1 67 | 6813 | / pin_project! { //~ ERROR reference to packed field is unaligned 6914 | | #[repr(packed(2))] 7015 | | struct PackedN { 7116 | | #[pin] 72... | 7319 | | } 74 | |_^ 75 | 76 = note: packed structs are only aligned by one byte, and many modern architectures penalize unaligned field accesses 77 = note: creating a misaligned reference is undefined behavior (even if that reference is never dereferenced) 78 = help: copy the field contents to a local variable, or replace the reference with a raw pointer and use `read_unaligned`/`write_unaligned` (loads and stores via `*p` must be properly aligned even when using raw pointers) 79 = note: this error originates in the macro `$crate::__pin_project_struct_make_proj_method` which comes from the expansion of the macro `pin_project` (in Nightly builds, run with -Z macro-backtrace for more info) 80 81error[E0793]: reference to packed field is unaligned 82 --> tests/ui/pin_project/packed.rs:13:1 83 | 8413 | / pin_project! { //~ ERROR reference to packed field is unaligned 8514 | | #[repr(packed(2))] 8615 | | struct PackedN { 8716 | | #[pin] 88... | 8919 | | } 90 | |_^ 91 | 92 = note: packed structs are only aligned by one byte, and many modern architectures penalize unaligned field accesses 93 = note: creating a misaligned reference is undefined behavior (even if that reference is never dereferenced) 94 = help: copy the field contents to a local variable, or replace the reference with a raw pointer and use `read_unaligned`/`write_unaligned` (loads and stores via `*p` must be properly aligned even when using raw pointers) 95 = note: this error originates in the macro `$crate::__pin_project_constant` which comes from the expansion of the macro `pin_project` (in Nightly builds, run with -Z macro-backtrace for more info) 96