We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 38d81f3 commit a7a2bc7Copy full SHA for a7a2bc7
tests/ui/use_self.fixed
@@ -422,3 +422,16 @@ mod lint_at_impl_item_level {
422
}
423
424
425
+
426
+mod issue4734 {
427
+ #[repr(C, packed)]
428
+ pub struct X {
429
+ pub x: u32,
430
+ }
431
432
+ impl From<X> for u32 {
433
+ fn from(c: X) -> Self {
434
+ unsafe { core::mem::transmute(c) }
435
436
437
+}
tests/ui/use_self.rs
0 commit comments