summaryrefslogtreecommitdiffstats
path: root/src/test/ui/rfcs/rfc1717/library-override.rs
blob: 014ccac31b7a55ce156571960bfa57e39515ce71 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
// run-pass
// ignore-wasm32-bare no libc to test ffi with
// compile-flags: -lstatic=wronglibrary:rust_test_helpers

#[link(name = "wronglibrary", kind = "dylib")]
extern "C" {
    pub fn rust_dbg_extern_identity_u32(x: u32) -> u32;
}

fn main() {
    unsafe {
        rust_dbg_extern_identity_u32(42);
    }
}