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]

va_list


According to Drepper (and one of his ISO C namespace conformance
checking programs), va_list must be a typedef, not a define.

I've checked this in to the mainline sources.  It is an extremely
minor problem, but I'd like to check it in to the release branch
as well.


r~


	* va-alpha.h (va_list): Use a typedef, not a define.
	* va-clipper.h (va_list): Likewise.

Index: va-alpha.h
===================================================================
RCS file: /egcs/carton/cvsfiles/egcs/gcc/ginclude/va-alpha.h,v
retrieving revision 1.1.1.1
diff -c -p -d -r1.1.1.1 va-alpha.h
*** va-alpha.h	1997/08/11 15:58:05	1.1.1.1
--- va-alpha.h	1998/08/02 00:50:03
*************** typedef struct {
*** 28,35 ****
  /* If this is for internal libc use, don't define anything but
     __gnuc_va_list.  */
  #if defined (_STDARG_H) || defined (_VARARGS_H)
  
- #define va_list __gnuc_va_list
  #define _VA_LIST
  #define _VA_LIST_
  
--- 28,35 ----
  /* If this is for internal libc use, don't define anything but
     __gnuc_va_list.  */
  #if defined (_STDARG_H) || defined (_VARARGS_H)
+ typedef __gnuc_va_list va_list;
  
  #define _VA_LIST
  #define _VA_LIST_
  
*************** enum {
*** 128,131 ****
  #define __va_copy(dest, src) (dest) = (src)
  
  #endif /* defined (_STDARG_H) || defined (_VARARGS_H) */
- 
--- 128,130 ----
Index: va-clipper.h
===================================================================
RCS file: /egcs/carton/cvsfiles/egcs/gcc/ginclude/va-clipper.h,v
retrieving revision 1.1.1.1
diff -c -p -d -r1.1.1.1 va-clipper.h
*** va-clipper.h	1997/08/11 15:58:05	1.1.1.1
--- va-clipper.h	1998/08/02 00:50:03
*************** typedef struct
*** 15,21 ****
  
  
  #if defined (_STDARG_H) || defined (_VARARGS_H)
! #define va_list __gnuc_va_list
  #define __va_list __gnuc_va_list	/* acc compatibility */
  
  #define _VA_LIST
--- 15,21 ----
  
  
  #if defined (_STDARG_H) || defined (_VARARGS_H)
! typedef __gnuc_va_list va_list;
  #define __va_list __gnuc_va_list	/* acc compatibility */
  
  #define _VA_LIST


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