ad053d66fe
previously we moved to the target block *before* calling a function, so when inspecting the stack, it appeared as if we were in the first statement of the next block.
10 lines
213 B
Rust
10 lines
213 B
Rust
#![feature(box_syntax)]
|
|
|
|
fn main() {
|
|
let x = box 42;
|
|
unsafe {
|
|
let f = std::mem::transmute::<Box<i32>, fn()>(x);
|
|
f() //~ ERROR: tried to treat a memory pointer as a function pointer
|
|
}
|
|
}
|