usebytemuck::TransparentWrapper;#[repr(transparent)]structWrap(Box<u32>);// SAFETY: it's #[repr(transparent)]
unsafeimplTransparentWrapper<Box<u32>>forWrap{}fnmain(){let value =Box::new(5);// This used to duplicate the wrapped value, creating a double free :(
Wrap::wrap(value);}