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]

[PATCH][3.3] Fix stdarg.h warning


Hi,

stdarg.h included in gcc 3.3-20031006 gave me a warning
while compiling a big project.

__STDC_VERSION__ was used even if not defined.

Hartmut

2003-10-08  Hartmut Schirmer  <hartmut.schirmer@arcor.de>

	* stdarg.h: Avoid warning about unknown __STDC_VERSION__


*** gcc/ginclude/stdarg.orig	Tue Jul 16 04:16:45 2002
--- gcc/ginclude/stdarg.h	Tue Oct  7 15:18:59 2003
*************** typedef __builtin_va_list __gnuc_va_list
*** 50,56 ****
  #define va_start(v,l)	__builtin_va_start(v,l)
  #define va_end(v)	__builtin_va_end(v)
  #define va_arg(v,l)	__builtin_va_arg(v,l)
! #if !defined(__STRICT_ANSI__) || __STDC_VERSION__ + 0 >= 199900L
  #define va_copy(d,s)	__builtin_va_copy(d,s)
  #endif
  #define __va_copy(d,s)	__builtin_va_copy(d,s)
--- 50,56 ----
  #define va_start(v,l)	__builtin_va_start(v,l)
  #define va_end(v)	__builtin_va_end(v)
  #define va_arg(v,l)	__builtin_va_arg(v,l)
! #if !defined(__STRICT_ANSI__) || (defined(__STDC_VERSION__) && __STDC_VERSION__ >= 199900L)
  #define va_copy(d,s)	__builtin_va_copy(d,s)
  #endif
  #define __va_copy(d,s)	__builtin_va_copy(d,s)






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