From 96398c4f92392c45e7dfdbccfdff655ebc9d75a4 Mon Sep 17 00:00:00 2001 From: Vern Paxson Date: Fri, 21 Apr 1995 11:51:51 +0000 Subject: [PATCH] reworked alloca() chud, from Francois --- parse.y | 38 ++++++++++++++++++++------------------ 1 file changed, 20 insertions(+), 18 deletions(-) diff --git a/parse.y b/parse.y index 645d549..650397b 100644 --- a/parse.y +++ b/parse.y @@ -42,9 +42,9 @@ */ #ifdef YYBISON /* AIX requires this to be the first thing in the file. What a piece. */ -#ifdef _AIX +# ifdef _AIX #pragma alloca -#endif +# endif #endif #include "flexdef.h" @@ -53,24 +53,26 @@ * so HAVE_ALLOCA_H is (possibly) defined. */ #ifdef YYBISON -#ifdef __GNUC__ -#define alloca __builtin_alloca -#else /* not __GNUC__ */ -#if HAVE_ALLOCA_H -#include -#else /* not HAVE_ALLOCA_H */ -#ifdef __hpux +# ifdef __GNUC__ +# ifndef alloca +# define alloca __builtin_alloca +# endif +# else +# if HAVE_ALLOCA_H +# include +# else +# ifdef __hpux void *alloca (); -#else /* not __hpux */ -#ifdef __TURBOC__ -#include -#else +# else +# ifdef __TURBOC__ +# include +# else char *alloca (); -#endif /* not __TURBOC__ */ -#endif /* not __hpux */ -#endif /* not HAVE_ALLOCA_H */ -#endif /* not __GNUC__ */ -#endif /* YYBISON */ +# endif +# endif +# endif +# endif +#endif /* Bletch, ^^^^ that was ugly! */ -- 2.40.0