defining.
* src/bison.s1: s/#ifdef YYLSP_NEEDED/#if YYLSP_NEEDED/.
+2000-11-07 Akim Demaille <akim@epita.fr>
+
+ * src/reader.c (reader): #define YYLSP_NEEDED to 1 instead of just
+ defining.
+ * src/bison.s1: s/#ifdef YYLSP_NEEDED/#if YYLSP_NEEDED/.
+
2000-11-07 Akim Demaille <akim@epita.fr>
* src/bison.s1 (YYLEX): Use #if instead of #ifdef.
/* YYLEX -- calling `yylex' with the right arguments. */
#if YYPURE
-# ifdef YYLSP_NEEDED
+# if YYLSP_NEEDED
# ifdef YYLEX_PARAM
# define YYLEX yylex (&yylval, &yylloc, YYLEX_PARAM)
# else
/* The semantic value of the lookahead symbol. */
YYSTYPE yylval;
-# ifdef YYLSP_NEEDED
+# if YYLSP_NEEDED
/* Location data for the lookahead symbol. */
YYLTYPE yylloc;
# endif
YYSTYPE *yyvs = yyvsa;
register YYSTYPE *yyvsp;
-#ifdef YYLSP_NEEDED
+#if YYLSP_NEEDED
/* The location stack. */
YYLTYPE yylsa[YYINITDEPTH];
YYLTYPE *yyls = yylsa;
YYLTYPE *yylsp;
#endif
-#ifdef YYLSP_NEEDED
+#if YYLSP_NEEDED
# define YYPOPSTACK (yyvsp--, yyssp--, yylsp--)
#else
# define YYPOPSTACK (yyvsp--, yyssp--)
int yychar;
YYSTYPE yylval;
int yynerrs;
-# ifdef YYLSP_NEEDED
+# if YYLSP_NEEDED
YYLTYPE yylloc;
# endif
#endif /* !YYPURE */
/* The variables used to return semantic value and location from the
action routines. */
YYSTYPE yyval;
-# ifdef YYLSP_NEEDED
+# if YYLSP_NEEDED
YYLTYPE yyloc;
# endif
yyssp = yyss - 1;
yyvsp = yyvs;
-#ifdef YYLSP_NEEDED
+#if YYLSP_NEEDED
yylsp = yyls;
#endif
*/
YYSTYPE *yyvs1 = yyvs;
short *yyss1 = yyss;
-#ifdef YYLSP_NEEDED
+#if YYLSP_NEEDED
YYLTYPE *yyls1 = yyls;
#endif
#ifdef yyoverflow
/* Each stack pointer address is followed by the size of
the data in use in that stack, in bytes. */
-# ifdef YYLSP_NEEDED
+# if YYLSP_NEEDED
/* This used to be a conditional around just the two extra args,
but that might be undefined if yyoverflow is a macro. */
yyoverflow ("parser stack overflow",
# endif
yyss = yyss1; yyvs = yyvs1;
-# ifdef YYLSP_NEEDED
+# if YYLSP_NEEDED
yyls = yyls1;
# endif
#else /* no yyoverflow */
{
free (yyss);
free (yyvs);
-# ifdef YYLSP_NEEDED
+# if YYLSP_NEEDED
free (yyls);
# endif
}
yyvs = (YYSTYPE *) YYSTACK_ALLOC (yystacksize * sizeof (*yyvsp));
__yy_memcpy ((char *)yyvs, (char *)yyvs1,
size * (unsigned int) sizeof (*yyvsp));
-# ifdef YYLSP_NEEDED
+# if YYLSP_NEEDED
yyls = (YYLTYPE *) YYSTACK_ALLOC (yystacksize * sizeof (*yylsp));
__yy_memcpy ((char *)yyls, (char *)yyls1,
size * (unsigned int) sizeof (*yylsp));
yyssp = yyss + size - 1;
yyvsp = yyvs + size - 1;
-#ifdef YYLSP_NEEDED
+#if YYLSP_NEEDED
yylsp = yyls + size - 1;
#endif
yychar = YYEMPTY;
*++yyvsp = yylval;
-#ifdef YYLSP_NEEDED
+#if YYLSP_NEEDED
*++yylsp = yylloc;
#endif
unconditionally makes the parser a bit smaller, and it avoids a
GCC warning that YYVAL may be used uninitialized. */
yyval = yyvsp[1-yylen];
-#ifdef YYLSP_NEEDED
+#if YYLSP_NEEDED
/* Implement default location. If the rhs is empty, extend YYLOC to
YYLLOC, which corresponds to the current token, otherwise
implement `@{dollar} = Starts at @1, ends at @YYLEN'. */
\f
yyvsp -= yylen;
yyssp -= yylen;
-#ifdef YYLSP_NEEDED
+#if YYLSP_NEEDED
yylsp -= yylen;
#endif
#endif
*++yyvsp = yyval;
-#ifdef YYLSP_NEEDED
+#if YYLSP_NEEDED
*++yylsp = yyloc;
#endif
YYABORT;
yyvsp--;
yystate = *--yyssp;
-#ifdef YYLSP_NEEDED
+#if YYLSP_NEEDED
yylsp--;
#endif
YYDPRINTF ((stderr, "Shifting error token, "));
*++yyvsp = yylval;
-#ifdef YYLSP_NEEDED
+#if YYLSP_NEEDED
*++yylsp = yylloc;
#endif
{
free (yyss);
free (yyvs);
-#ifdef YYLSP_NEEDED
+#if YYLSP_NEEDED
free (yyls);
#endif
}
{
free (yyss);
free (yyvs);
-#ifdef YYLSP_NEEDED
+#if YYLSP_NEEDED
free (yyls);
#endif
}
/* YYLEX -- calling `yylex' with the right arguments. */
#if YYPURE
-# ifdef YYLSP_NEEDED
+# if YYLSP_NEEDED
# ifdef YYLEX_PARAM
# define YYLEX yylex (&yylval, &yylloc, YYLEX_PARAM)
# else
/* The semantic value of the lookahead symbol. */
YYSTYPE yylval;
-# ifdef YYLSP_NEEDED
+# if YYLSP_NEEDED
/* Location data for the lookahead symbol. */
YYLTYPE yylloc;
# endif
YYSTYPE *yyvs = yyvsa;
register YYSTYPE *yyvsp;
-#ifdef YYLSP_NEEDED
+#if YYLSP_NEEDED
/* The location stack. */
YYLTYPE yylsa[YYINITDEPTH];
YYLTYPE *yyls = yylsa;
YYLTYPE *yylsp;
#endif
-#ifdef YYLSP_NEEDED
+#if YYLSP_NEEDED
# define YYPOPSTACK (yyvsp--, yyssp--, yylsp--)
#else
# define YYPOPSTACK (yyvsp--, yyssp--)
int yychar;
YYSTYPE yylval;
int yynerrs;
-# ifdef YYLSP_NEEDED
+# if YYLSP_NEEDED
YYLTYPE yylloc;
# endif
#endif /* !YYPURE */
/* The variables used to return semantic value and location from the
action routines. */
YYSTYPE yyval;
-# ifdef YYLSP_NEEDED
+# if YYLSP_NEEDED
YYLTYPE yyloc;
# endif
yyssp = yyss - 1;
yyvsp = yyvs;
-#ifdef YYLSP_NEEDED
+#if YYLSP_NEEDED
yylsp = yyls;
#endif
*/
YYSTYPE *yyvs1 = yyvs;
short *yyss1 = yyss;
-#ifdef YYLSP_NEEDED
+#if YYLSP_NEEDED
YYLTYPE *yyls1 = yyls;
#endif
#ifdef yyoverflow
/* Each stack pointer address is followed by the size of
the data in use in that stack, in bytes. */
-# ifdef YYLSP_NEEDED
+# if YYLSP_NEEDED
/* This used to be a conditional around just the two extra args,
but that might be undefined if yyoverflow is a macro. */
yyoverflow ("parser stack overflow",
# endif
yyss = yyss1; yyvs = yyvs1;
-# ifdef YYLSP_NEEDED
+# if YYLSP_NEEDED
yyls = yyls1;
# endif
#else /* no yyoverflow */
{
free (yyss);
free (yyvs);
-# ifdef YYLSP_NEEDED
+# if YYLSP_NEEDED
free (yyls);
# endif
}
yyvs = (YYSTYPE *) YYSTACK_ALLOC (yystacksize * sizeof (*yyvsp));
__yy_memcpy ((char *)yyvs, (char *)yyvs1,
size * (unsigned int) sizeof (*yyvsp));
-# ifdef YYLSP_NEEDED
+# if YYLSP_NEEDED
yyls = (YYLTYPE *) YYSTACK_ALLOC (yystacksize * sizeof (*yylsp));
__yy_memcpy ((char *)yyls, (char *)yyls1,
size * (unsigned int) sizeof (*yylsp));
yyssp = yyss + size - 1;
yyvsp = yyvs + size - 1;
-#ifdef YYLSP_NEEDED
+#if YYLSP_NEEDED
yylsp = yyls + size - 1;
#endif
yychar = YYEMPTY;
*++yyvsp = yylval;
-#ifdef YYLSP_NEEDED
+#if YYLSP_NEEDED
*++yylsp = yylloc;
#endif
unconditionally makes the parser a bit smaller, and it avoids a
GCC warning that YYVAL may be used uninitialized. */
yyval = yyvsp[1-yylen];
-#ifdef YYLSP_NEEDED
+#if YYLSP_NEEDED
/* Implement default location. If the rhs is empty, extend YYLOC to
YYLLOC, which corresponds to the current token, otherwise
implement `@{dollar} = Starts at @1, ends at @YYLEN'. */
\f
yyvsp -= yylen;
yyssp -= yylen;
-#ifdef YYLSP_NEEDED
+#if YYLSP_NEEDED
yylsp -= yylen;
#endif
#endif
*++yyvsp = yyval;
-#ifdef YYLSP_NEEDED
+#if YYLSP_NEEDED
*++yylsp = yyloc;
#endif
YYABORT;
yyvsp--;
yystate = *--yyssp;
-#ifdef YYLSP_NEEDED
+#if YYLSP_NEEDED
yylsp--;
#endif
YYDPRINTF ((stderr, "Shifting error token, "));
*++yyvsp = yylval;
-#ifdef YYLSP_NEEDED
+#if YYLSP_NEEDED
*++yylsp = yylloc;
#endif
{
free (yyss);
free (yyvs);
-#ifdef YYLSP_NEEDED
+#if YYLSP_NEEDED
free (yyls);
#endif
}
{
free (yyss);
free (yyvs);
-#ifdef YYLSP_NEEDED
+#if YYLSP_NEEDED
free (yyls);
#endif
}
/* Write closing delimiters for actions and guards. */
output_trailers ();
if (locations_flag)
- obstack_grow_literal_string (&table_obstack, "#define YYLSP_NEEDED\n\n");
+ obstack_grow_literal_string (&table_obstack, "#define YYLSP_NEEDED 1\n\n");
/* Assign the symbols their symbol numbers. Write #defines for the
token symbols into FDEFINES if requested. */
packsymbols ();