# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
-# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
-# 02111-1307 USA
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+# 02110-1301 USA
m4_divert(0)dnl
@output @output_parser_name@
b4_copyright([Skeleton parser for Yacc-like parsing with Bison],
- [1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004])[
+ [1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005])[
/* As a special exception, when this file is copied by Bison into a
Bison output file, you may use that output file without restriction.
/* Line __line__ of yacc.c. */
b4_syncline([@oline@], [@ofile@])[
-#if ! defined (yyoverflow) || YYERROR_VERBOSE
+#if ! defined (YYSIZE_T) && defined (__SIZE_TYPE__)
+# define YYSIZE_T __SIZE_TYPE__
+#endif
+#if ! defined (YYSIZE_T) && defined (size_t)
+# define YYSIZE_T size_t
+#endif
+#if ! defined (YYSIZE_T) && (defined (__STDC__) || defined (__cplusplus))
+# include <stddef.h> /* INFRINGES ON USER NAME SPACE */
+# define YYSIZE_T size_t
+#endif
+#if ! defined (YYSIZE_T)
+# define YYSIZE_T unsigned int
+#endif
-# ifndef YYFREE
-# define YYFREE free
-# endif
-# ifndef YYMALLOC
-# define YYMALLOC malloc
-# endif
+#if ! defined (yyoverflow) || YYERROR_VERBOSE
/* The parser invokes alloca or malloc; define the necessary symbols. */
# define YYSTACK_ALLOC __builtin_alloca
# else
# define YYSTACK_ALLOC alloca
+# if defined (__STDC__) || defined (__cplusplus)
+# include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
+# define YYINCLUDED_STDLIB_H
+# endif
# endif
# endif
# endif
# define YYSTACK_ALLOC_MAXIMUM 4032 /* reasonable circa 2005 */
# endif
# else
-# if defined (__STDC__) || defined (__cplusplus)
-# include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
-# define YYSIZE_T size_t
-# else
-# define YYSIZE_T unsigned long int
-# endif
# define YYSTACK_ALLOC YYMALLOC
# define YYSTACK_FREE YYFREE
# ifndef YYSTACK_ALLOC_MAXIMUM
# define YYSTACK_ALLOC_MAXIMUM ((YYSIZE_T) -1)
# endif
+# ifdef __cplusplus
+extern "C" {
+# endif
+# ifndef YYMALLOC
+# define YYMALLOC malloc
+# if (! defined (malloc) && ! defined (YYINCLUDED_STDLIB_H) \
+ && (defined (__STDC__) || defined (__cplusplus)))
+void *malloc (YYSIZE_T); /* INFRINGES ON USER NAME SPACE */
+# endif
+# endif
+# ifndef YYFREE
+# define YYFREE free
+# if (! defined (free) && ! defined (YYINCLUDED_STDLIB_H) \
+ && (defined (__STDC__) || defined (__cplusplus)))
+void free (void *); /* INFRINGES ON USER NAME SPACE */
+# endif
+# endif
+# ifdef __cplusplus
+}
+# endif
# endif
#endif /* ! defined (yyoverflow) || YYERROR_VERBOSE */
};
#endif
-/* INFRINGES ON USER NAME SPACE */
-#ifndef _
-# define _(msgid) msgid
+#ifndef YYI18N
+# if YYENABLE_NLS
+# if ENABLE_NLS
+# include <libintl.h> /* INFRINGES ON USER NAME SPACE */
+# define YYI18N(msgid) dgettext ("bison-runtime", msgid)
+# endif
+# endif
+# ifndef YYI18N
+# define YYI18N(msgid) msgid
+# endif
#endif
# ifdef YYPRINT
]b4_stos[
};
-#if ! defined (YYSIZE_T) && defined (__SIZE_TYPE__)
-# define YYSIZE_T __SIZE_TYPE__
-#endif
-#if ! defined (YYSIZE_T) && defined (size_t)
-# define YYSIZE_T size_t
-#endif
-#if ! defined (YYSIZE_T)
-# if defined (__STDC__) || defined (__cplusplus)
-# include <stddef.h> /* INFRINGES ON USER NAME SPACE */
-# define YYSIZE_T size_t
-# endif
-#endif
-#if ! defined (YYSIZE_T)
-# define YYSIZE_T unsigned int
-#endif
-
#define yyerrok (yyerrstatus = 0)
#define yyclearin (yychar = YYEMPTY)
#define YYEMPTY (-2)
} \
else \
{ \
- yyerror (]b4_yyerror_args[_("syntax error: cannot back up")); \
+ yyerror (]b4_yyerror_args[YYI18N ("syntax error: cannot back up")); \
YYERROR; \
} \
while (0)
[[short int *bottom], [bottom]],
[[short int *top], [top]])[
{
- YYFPRINTF (stderr, _("Stack now"));
+ YYFPRINTF (stderr, YYI18N ("Stack now"));
for (/* Nothing. */; bottom <= top; ++bottom)
YYFPRINTF (stderr, " %d", *bottom);
YYFPRINTF (stderr, "\n");
{
int yyi;
unsigned int yylno = yyrline[yyrule];
- YYFPRINTF (stderr, _("Reducing stack by rule %d (line %u), "),
+ YYFPRINTF (stderr, YYI18N ("Reducing stack by rule %d (line %u), "),
yyrule - 1, yylno);
/* Print the symbols being reduced, and their result. */
for (yyi = yyprhs[yyrule]; 0 <= yyrhs[yyi]; yyi++)
#endif
]])
m4_ifdef([b4_initial_action], [
-m4_pushdef([b4_at_dollar], [yylloc])dnl
-m4_pushdef([b4_dollar_dollar], [yylval])dnl
+m4_pushdef([b4_at_dollar], [m4_define([b4_at_dollar_used])yylloc])dnl
+m4_pushdef([b4_dollar_dollar], [m4_define([b4_dollar_dollar_used])yylval])dnl
/* User initialization code. */
b4_initial_action
m4_popdef([b4_dollar_dollar])dnl
m4_popdef([b4_at_dollar])dnl
/* Line __line__ of yacc.c. */
-b4_syncline([@oline@], [@ofile@])])dnl
-[
- yyvsp[0] = yylval;
-]b4_location_if([[ yylsp[0] = yylloc;
-]])
+b4_syncline([@oline@], [@ofile@])
+])dnl
+m4_ifdef([b4_dollar_dollar_used],[[ yyvsp[0] = yylval;
+]])dnl
+m4_ifdef([b4_at_dollar_used], [[ yylsp[0] = yylloc;
+]])dnl
[ goto yysetstate;
/*------------------------------------------------------------.
data in use in that stack, in bytes. 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"),
+ yyoverflow (YYI18N ("parser stack overflow"),
&yyss1, yysize * sizeof (*yyssp),
&yyvs1, yysize * sizeof (*yyvsp),
]b4_location_if([ &yyls1, yysize * sizeof (*yylsp),])[
yyvsp = yyvs + yysize - 1;
]b4_location_if([ yylsp = yyls + yysize - 1;])[
- YYDPRINTF ((stderr, _("Stack size increased to %lu\n"),
+ YYDPRINTF ((stderr, YYI18N ("Stack size increased to %lu\n"),
(unsigned long int) yystacksize));
if (yyss + yystacksize - 1 <= yyssp)
YYABORT;
}
- YYDPRINTF ((stderr, _("Entering state %d\n"), yystate));
+ YYDPRINTF ((stderr, YYI18N ("Entering state %d\n"), yystate));
goto yybackup;
/* YYCHAR is either YYEMPTY or YYEOF or a valid look-ahead symbol. */
if (yychar == YYEMPTY)
{
- YYDPRINTF ((stderr, _("Reading a token: ")));
+ YYDPRINTF ((stderr, YYI18N ("Reading a token: ")));
yychar = YYLEX;
}
if (yychar <= YYEOF)
{
yychar = yytoken = YYEOF;
- YYDPRINTF ((stderr, _("Now at end of input.\n")));
+ YYDPRINTF ((stderr, YYI18N ("Now at end of input.\n")));
}
else
{
yytoken = YYTRANSLATE (yychar);
- YY_SYMBOL_PRINT (_("Next token is"), yytoken, &yylval, &yylloc);
+ YY_SYMBOL_PRINT (YYI18N ("Next token is"), yytoken, &yylval, &yylloc);
}
/* If the proper action on seeing token YYTOKEN is to reduce or to
YYACCEPT;
/* Shift the look-ahead token. */
- YY_SYMBOL_PRINT (_("Shifting"), yytoken, &yylval, &yylloc);
+ YY_SYMBOL_PRINT (YYI18N ("Shifting"), yytoken, &yylval, &yylloc);
/* Discard the token being shifted unless it is eof. */
if (yychar != YYEOF)
#if 0
/* This is so xgettext sees the translatable formats that are
constructed on the fly. */
- _("syntax error, unexpected %s");
- _("syntax error, unexpected %s, expecting %s");
- _("syntax error, unexpected %s, expecting %s or %s");
- _("syntax error, unexpected %s, expecting %s or %s or %s");
- _("syntax error, unexpected %s, expecting %s or %s or %s or %s");
+ YYI18N ("syntax error, unexpected %s");
+ YYI18N ("syntax error, unexpected %s, expecting %s");
+ YYI18N ("syntax error, unexpected %s, expecting %s or %s");
+ YYI18N ("syntax error, unexpected %s, expecting %s or %s or %s");
+ YYI18N ("syntax error, unexpected %s, expecting %s or %s or %s or %s");
#endif
char *yyfmt;
char const *yyf;
yyprefix = yyor;
}
- yyf = _(yyformat);
- yysize1 = yysize + strlen (yyf);
+ yyf = YYI18N (yyformat);
+ yysize1 = yysize + yystrlen (yyf);
yysize_overflow |= yysize1 < yysize;
yysize = yysize1;
YYSTACK_FREE (yymsg);
}
else
- yyerror (]b4_yyerror_args[_("syntax error; also memory exhausted"));
+ yyerror (]b4_yyerror_args[YYI18N ("syntax error; also memory exhausted"));
}
else
#endif /* YYERROR_VERBOSE */
- yyerror (]b4_yyerror_args[_("syntax error"));
+ yyerror (]b4_yyerror_args[YYI18N ("syntax error"));
}
]b4_location_if([[ yyerror_range[0] = yylloc;]])[
}
else
{
- yydestruct (_("Error: discarding"), yytoken, &yylval]b4_location_if([, &yylloc])[);
+ yydestruct (YYI18N ("Error: discarding"), yytoken, &yylval]b4_location_if([, &yylloc])[);
yychar = YYEMPTY;
}
}
YYABORT;
]b4_location_if([[ yyerror_range[0] = *yylsp;]])[
- yydestruct (_("Error: popping"), yystos[yystate], yyvsp]b4_location_if([, yylsp])[);
+ yydestruct (YYI18N ("Error: popping"), yystos[yystate], yyvsp]b4_location_if([, yylsp])[);
YYPOPSTACK;
yystate = *yyssp;
YY_STACK_PRINT (yyss, yyssp);
*++yylsp = yyloc;]])[
/* Shift the error token. */
- YY_SYMBOL_PRINT (_("Shifting"), yystos[yyn], yyvsp, yylsp);
+ YY_SYMBOL_PRINT (YYI18N ("Shifting"), yystos[yyn], yyvsp, yylsp);
yystate = yyn;
goto yynewstate;
| yyabortlab -- YYABORT comes here. |
`-----------------------------------*/
yyabortlab:
- yydestruct (_("Error: discarding lookahead"),
- yytoken, &yylval]b4_location_if([, &yylloc])[);
- yychar = YYEMPTY;
yyresult = 1;
goto yyreturn;
| yyoverflowlab -- parser overflow comes here. |
`----------------------------------------------*/
yyoverflowlab:
- yyerror (]b4_yyerror_args[_("parser stack overflow"));
- yydestruct (_("Error: discarding lookahead"),
- yytoken, &yylval]b4_location_if([, &yylloc])[);
+ yyerror (]b4_yyerror_args[YYI18N ("parser stack overflow"));
yyresult = 2;
/* Fall through. */
#endif
yyreturn:
+ if (yychar != YYEOF && yychar != YYEMPTY)
+ yydestruct (YYI18N ("Error: discarding lookahead"),
+ yytoken, &yylval]b4_location_if([, &yylloc])[);
if (yyssp != yyss)
for (;;)
{
YYPOPSTACK;
if (yyssp == yyss)
break;
- yydestruct (_("Error: popping"),
+ yydestruct (YYI18N ("Error: popping"),
yystos[*yyssp], yyvsp]b4_location_if([, yylsp])[);
}
#ifndef yyoverflow
m4_if(b4_defines_flag, 0, [],
[@output @output_header_name@
b4_copyright([Skeleton parser for Yacc-like parsing with Bison],
- [1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004])
+ [1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005])
/* As a special exception, when this file is copied by Bison into a
Bison output file, you may use that output file without restriction.