Files
rust/tests/ui/c-variadic/fn-item-diagnostic-issue-69232.rs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

14 lines
226 B
Rust
Raw Normal View History

2024-11-27 15:37:27 +01:00
// https://github.com/rust-lang/rust/issues/69232
extern "C" {
fn foo(x: usize, ...);
}
fn test() -> u8 {
127
}
fn main() {
unsafe { foo(1, test) }; //~ ERROR can't pass a function item to a variadic function
}