(va_list) [__SVR4_2__]: Don't set or test _VA_LIST.
authorRichard Stallman <rms@gnu.org>
Sat, 17 Oct 1992 07:39:31 +0000 (07:39 +0000)
committerRichard Stallman <rms@gnu.org>
Sat, 17 Oct 1992 07:39:31 +0000 (07:39 +0000)
From-SVN: r2500

gcc/ginclude/stdarg.h
gcc/ginclude/varargs.h

index 85cb3a9046083cbd05fbd39a0888a09372926d46..c93240ef99b5b00e2e1f51b315e701b3f626fcd4 100644 (file)
@@ -94,6 +94,15 @@ void va_end (__gnuc_va_list);                /* Defined in libgcc.a */
 #undef _BSD_VA_LIST
 #endif
 
+#ifdef __SVR4_2__
+/* SVR4.2 uses _VA_LIST for an internal alias for va_list,
+   so we must avoid testing it and setting it here.  */
+#ifndef _VA_LIST_
+#define _VA_LIST_
+typedef __gnuc_va_list va_list;
+#endif /* _VA_LIST_ */
+#else /* not __SVR4_2__ */
+
 /* The macro _VA_LIST_ is the same thing used by this file in Ultrix.  */
 #ifndef _VA_LIST_
 /* The macro _VA_LIST is used in SCO Unix 3.2.  */
@@ -103,6 +112,9 @@ void va_end (__gnuc_va_list);               /* Defined in libgcc.a */
 typedef __gnuc_va_list va_list;
 #endif /* _VA_LIST */
 #endif /* _VA_LIST_ */
+
+#endif /* not __SVR4_2__ */
+
 #endif /* _STDARG_H */
 
 #endif /* __GNUC__ */
index 7df05ae7e5ec7b2628524cef53195b1c49cdb5fb..ef2eeaffa10089050e4a7c73595d902b1658b1d4 100644 (file)
@@ -115,6 +115,17 @@ typedef void *__gnuc_va_list;
 #undef _VA_LIST_
 #endif
 
+#ifdef __SVR4_2__
+
+/* SVR4.2 uses _VA_LIST for an internal alias for va_list,
+   so we must avoid testing it and setting it here.  */
+#ifndef _VA_LIST_
+#define _VA_LIST_
+typedef __gnuc_va_list va_list;
+#endif /* _VA_LIST_ */
+
+#else /* not __SVR4_2__ */
+
 /* The macro _VA_LIST_ is the same thing used by this file in Ultrix.  */
 #ifndef _VA_LIST_
 /* The macro _VA_LIST is used in SCO Unix 3.2.  */
@@ -125,6 +136,8 @@ typedef __gnuc_va_list va_list;
 #endif /* _VA_LIST */
 #endif /* _VA_LIST_ */
 
+#endif /* not __SVR4_2__ */
+
 /*  I think that in 4.3bsd-net2 there is some need
     to leave _VA_LIST_ undefined after.  I don't know why. -- rms.  */
 #ifdef _ANSI_H_