mirror of
https://github.com/ziglang/zig.git
synced 2025-12-06 14:23:09 +00:00
As calling convention may not be specified explicitly in the source, so use va_arg's location instead. Signed-off-by: Tw <tw19881113@gmail.com>
18 lines
444 B
Zig
18 lines
444 B
Zig
fn foo(...) void {}
|
|
inline fn foo2(...) void {}
|
|
|
|
comptime {
|
|
_ = foo;
|
|
}
|
|
comptime {
|
|
_ = foo2;
|
|
}
|
|
|
|
// error
|
|
// target=x86_64-linux
|
|
//
|
|
// :1:8: error: variadic function does not support 'auto' calling convention
|
|
// :1:8: note: supported calling conventions: 'x86_64_sysv', 'x86_64_win'
|
|
// :2:16: error: variadic function does not support 'inline' calling convention
|
|
// :2:16: note: supported calling conventions: 'x86_64_sysv', 'x86_64_win'
|