rust/tests/run-pass/cast_fn_ptr_unsafe.rs

9 lines
99 B
Rust
Raw Normal View History

fn main() {
fn f() {}
let g = f as fn() as unsafe fn();
unsafe {
g();
}
}