New, from PR 14498.
authorDale Johannesen <dalej@gcc.gnu.org>
Fri, 28 May 2004 17:09:22 +0000 (17:09 +0000)
committerDale Johannesen <dalej@gcc.gnu.org>
Fri, 28 May 2004 17:09:22 +0000 (17:09 +0000)
From-SVN: r82368

gcc/testsuite/gcc.dg/va-arg-3.c [new file with mode: 0644]

diff --git a/gcc/testsuite/gcc.dg/va-arg-3.c b/gcc/testsuite/gcc.dg/va-arg-3.c
new file mode 100644 (file)
index 0000000..ef2344b
--- /dev/null
@@ -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);
+    }
+}