]> git.lizzy.rs Git - rust.git/blob - src/test/ui/c-variadic/issue-32201.rs
Merge commit 'e9d1a0a7b0b28dd422f1a790ccde532acafbf193' into sync_cg_clif-2022-08-24
[rust.git] / src / test / ui / c-variadic / issue-32201.rs
1 extern "C" {
2     fn foo(a: i32, ...);
3 }
4
5 fn bar(_: *const u8) {}
6
7 fn main() {
8     unsafe {
9         foo(0, bar);
10         //~^ ERROR can't pass `fn(*const u8) {bar}` to variadic function
11         //~| HELP cast the value to `fn(*const u8)`
12     }
13 }