This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] va_copy(va_list, const va_list)


Richard Henderson wrote:
Please add a test case as well.

Attached.


Earl

--- /dev/null 2004-10-22 14:50:16.524000000 -0700
+++ gcc-3.4.1/gcc/testsuite/gcc.dg/20041022-1.c 2004-10-22 14:49:33.243603300 -0700
@@ -0,0 +1,14 @@
+/* Verify that va_copy() can successfully copy from const qualified
+ va_list. */
+
+/* { dg-do compile */
+/* { dg-options "-Werror" */
+
+#include <stdarg.h>
+
+void vacopy(const va_list arglist)
+{
+ va_list copylist;
+
+ va_copy(copylist, arglist);
+}



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]