//@ compile-flags: -Zinline-mir=yes --crate-type=lib //@ build-pass use std::mem::ManuallyDrop; pub struct Foo([T; N]); pub struct Dorp {} impl Drop for Dorp { fn drop(&mut self) {} } #[inline] // SAFETY: call this with a valid allocation idk pub unsafe fn drop(x: *mut Foo) { std::ptr::drop_in_place(x); }