rust/tests/fail/function_calls/exported_symbol_wrong_arguments.rs
2022-07-11 11:48:56 +00:00

10 lines
179 B
Rust

#[no_mangle]
fn foo() {}
fn main() {
extern "Rust" {
fn foo(_: i32);
}
unsafe { foo(1) } //~ ERROR: calling a function with more arguments than it expected
}