diff options
-rw-r--r-- | gcc/testsuite/gcc.dg/va-arg-3.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/gcc/testsuite/gcc.dg/va-arg-3.c b/gcc/testsuite/gcc.dg/va-arg-3.c new file mode 100644 index 0000000..ef2344b --- /dev/null +++ b/gcc/testsuite/gcc.dg/va-arg-3.c @@ -0,0 +1,13 @@ +/* { dg-do compile } */ +/* { dg-options "-O3" } */ +/* PR 14498. */ +#include <stdarg.h> +extern void baz(char *); +void bar (va_list *args) +{ + if (args) + { + char *s = va_arg(*args, char *); + baz(s); + } +} |