rust/src/test/compile-fail/unsafe-fn-called-from-safe.rs
2012-08-01 19:16:06 -07:00

8 lines
137 B
Rust

// -*- rust -*-
unsafe fn f() { return; }
fn main() {
f(); //~ ERROR access to unsafe function requires unsafe function or block
}