Parse ... as a VaList

This commit is contained in:
Sjors Holtrop
2023-01-03 19:55:57 +01:00
committed by Emilio Cobos Álvarez
parent 5778380ba1
commit c8546ad42d
6 changed files with 16 additions and 0 deletions
+2
View File
@@ -4,3 +4,5 @@
#include <stdlib.h>
int32_t va_list_test(va_list ap);
int32_t va_list_test2(va_list ap);
+2
View File
@@ -9,6 +9,8 @@ extern "C" {
int32_t va_list_test(va_list ap);
int32_t va_list_test2(va_list ap);
#ifdef __cplusplus
} // extern "C"
#endif // __cplusplus
+2
View File
@@ -8,4 +8,6 @@ extern "C" {
int32_t va_list_test(va_list ap);
int32_t va_list_test2(va_list ap);
} // extern "C"
+2
View File
@@ -7,3 +7,5 @@ cdef extern from *:
cdef extern from *:
int32_t va_list_test(va_list ap);
int32_t va_list_test2(va_list ap);
+5
View File
@@ -4,3 +4,8 @@ use std::ffi::VaList;
pub unsafe extern "C" fn va_list_test(mut ap: VaList) -> int32_t {
ap.arg()
}
#[no_mangle]
pub unsafe extern "C" fn va_list_test2(mut ap: ...) -> int32_t {
ap.arg()
}