From: Paul Eggert Date: Sun, 19 Dec 2004 13:42:26 +0000 (+0000) Subject: Include only if HAVE_ALLOCA. X-Git-Tag: v5.3.0~108 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=13389908dd45f4aa072f5019e222b9a560c363f7;p=thirdparty%2Fcoreutils.git Include only if HAVE_ALLOCA. (YYSTACK_USE_ALLOCA): Define to 0 if !HAVE_ALLOCA. (YYMAXDEPTH): New macro. --- diff --git a/lib/getdate.y b/lib/getdate.y index 6ffee30b96..b57e6a56d3 100644 --- a/lib/getdate.y +++ b/lib/getdate.y @@ -36,7 +36,18 @@ #include "getdate.h" -#include +/* Use alloca only if it is known to be builtin. */ +#if HAVE_ALLOCA +# include +#else +# define YYSTACK_USE_ALLOCA 0 +#endif + +/* Tell Bison ow much stack space is needed. 20 should be plenty for + this grammar, which is not right recursive. Beware setting it too + high, since that might cause problems on machines whose alloca + implementations have lame stack-overflow checking. */ +#define YYMAXDEPTH 20 /* Since the code of getdate.y is not included in the Emacs executable itself, there is no need to #define static in this file. Even if