// error-pattern: tried to deallocate Stack memory but gave Rust as the kind fn main() { let x = 42; let bad_box = unsafe { std::mem::transmute::<&i32, Box>(&x) }; drop(bad_box); }