mirror of
https://github.com/enjoy-digital/litex.git
synced 2025-01-04 09:52:26 -05:00
software: stdarg.h: cleanup and add va_copy
This commit is contained in:
parent
5fe1aade34
commit
964dc8050c
1 changed files with 5 additions and 14 deletions
|
@ -3,20 +3,11 @@
|
|||
|
||||
#include <stdlib.h>
|
||||
|
||||
#if (__GNUC__ > 4) || ((__GNUC__ == 4) && (__GNUC_MINOR__ >= 4))
|
||||
#define va_start(v,l) __builtin_va_start((v),l)
|
||||
#else
|
||||
#define va_start(v,l) __builtin_stdarg_start((v),l)
|
||||
#endif
|
||||
|
||||
#define va_arg(ap, type) \
|
||||
__builtin_va_arg((ap), type)
|
||||
|
||||
#define va_end(ap) \
|
||||
__builtin_va_end(ap)
|
||||
|
||||
#define va_list \
|
||||
__builtin_va_list
|
||||
#define va_start(v, l) __builtin_va_start((v), l)
|
||||
#define va_arg(ap, type) __builtin_va_arg((ap), type)
|
||||
#define va_copy(aq, ap) __builtin_va_copy((aq), (ap))
|
||||
#define va_end(ap) __builtin_va_end(ap)
|
||||
#define va_list __builtin_va_list
|
||||
|
||||
int vsnprintf(char *buf, size_t size, const char *fmt, va_list args);
|
||||
int vscnprintf(char *buf, size_t size, const char *fmt, va_list args);
|
||||
|
|
Loading…
Reference in a new issue