summaryrefslogtreecommitdiff
path: root/parse.y
diff options
context:
space:
mode:
authorVern Paxson <vern@ee.lbl.gov>1995-04-20 12:42:37 +0000
committerVern Paxson <vern@ee.lbl.gov>1995-04-20 12:42:37 +0000
commit34ba5a8132b45d84277ed880490685e68e68335c (patch)
treeb0bea96659b82d9e5652ccce931e827ccf774267 /parse.y
parentf3c56e55116a92cfc25480eea8337e94ddaacb03 (diff)
more alloca() bullshit
Diffstat (limited to 'parse.y')
-rw-r--r--parse.y19
1 files changed, 12 insertions, 7 deletions
diff --git a/parse.y b/parse.y
index 93a57b2..645d549 100644
--- a/parse.y
+++ b/parse.y
@@ -41,16 +41,24 @@
* #ifdef chud to fix the problem, courtesy of Francois Pinard.
*/
#ifdef YYBISON
-/* AIX requires this to be the first thing in the file. */
+/* AIX requires this to be the first thing in the file. What a piece. */
+#ifdef _AIX
+ #pragma alloca
+#endif
+#endif
+
+#include "flexdef.h"
+
+/* The remainder of the alloca() cruft has to come after including flexdef.h,
+ * so HAVE_ALLOCA_H is (possibly) defined.
+ */
+#ifdef YYBISON
#ifdef __GNUC__
#define alloca __builtin_alloca
#else /* not __GNUC__ */
#if HAVE_ALLOCA_H
#include <alloca.h>
#else /* not HAVE_ALLOCA_H */
-#ifdef _AIX
- #pragma alloca
-#else /* not _AIX */
#ifdef __hpux
void *alloca ();
#else /* not __hpux */
@@ -60,7 +68,6 @@ void *alloca ();
char *alloca ();
#endif /* not __TURBOC__ */
#endif /* not __hpux */
-#endif /* not _AIX */
#endif /* not HAVE_ALLOCA_H */
#endif /* not __GNUC__ */
#endif /* YYBISON */
@@ -68,8 +75,6 @@ char *alloca ();
/* Bletch, ^^^^ that was ugly! */
-#include "flexdef.h"
-
int pat, scnum, eps, headcnt, trailcnt, anyccl, lastchar, i, rulelen;
int trlcontxt, xcluflg, currccl, cclsorted, varlength, variable_trail_rule;