about summary refs log tree commit diff
path: root/src/tools/miri/tests/native-lib/fail/function_not_in_so.rs
blob: a7df3e6118725c196a3f5c71ea966e9afb194d3b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
// Only works on Unix targets
//@ignore-target: windows wasm
//@only-on-host
//@normalize-stderr-test: "OS `.*`" -> "$$OS"

extern "C" {
    fn foo();
}

fn main() {
    unsafe {
        foo(); //~ ERROR: unsupported operation: can't call foreign function `foo`
    }
}