re PR c++/11929 (Cannot obtain variable arguments list in function with last named...
authorJason Merrill <jason@gcc.gnu.org>
Tue, 9 Dec 2003 04:08:20 +0000 (23:08 -0500)
committerJason Merrill <jason@gcc.gnu.org>
Tue, 9 Dec 2003 04:08:20 +0000 (23:08 -0500)
        PR c++/11929
        * call.c (magic_varargs_p): New fn.
        (build_over_call): Do no ellipsis conversions for arguments to
        functions with magic varargs.

From-SVN: r74461

gcc/testsuite/g++.dg/other/stdarg2.C [new file with mode: 0644]

diff --git a/gcc/testsuite/g++.dg/other/stdarg2.C b/gcc/testsuite/g++.dg/other/stdarg2.C
new file mode 100644 (file)
index 0000000..99e9040
--- /dev/null
@@ -0,0 +1,12 @@
+// PR c++/11929
+// Bug: We were complaining about the call to va_start because o is of
+// non-POD type.
+
+struct s {
+  s(int);
+};
+
+void test(s o, ...) {
+  __builtin_va_list varg;
+  __builtin_va_start(varg, o);
+}