X-Git-Url: https://git.draconx.ca/gitweb/gob-dx.git/blobdiff_plain/6bec711e14babb0d6388754f41834036f22a3ef1..d52e64e92557f0b6d7704077ec175c88fa7ca243:/src/parse.c diff --git a/src/parse.c b/src/parse.c index 8145ee5..0c3a4ad 100644 --- a/src/parse.c +++ b/src/parse.c @@ -1,9 +1,8 @@ -/* A Bison parser, made by GNU Bison 2.4.3. */ +/* A Bison parser, made by GNU Bison 2.5. */ -/* Skeleton implementation for Bison's Yacc-like parsers in C +/* Bison implementation for Yacc-like parsers in C - Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006, - 2009, 2010 Free Software Foundation, Inc. + Copyright (C) 1984, 1989-1990, 2000-2011 Free Software Foundation, Inc. This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -45,7 +44,7 @@ #define YYBISON 1 /* Bison version. */ -#define YYBISON_VERSION "2.4.3" +#define YYBISON_VERSION "2.5" /* Skeleton name. */ #define YYSKELETON_NAME "yacc.c" @@ -66,7 +65,7 @@ /* Copy the first part of user declarations. */ -/* Line 189 of yacc.c */ +/* Line 268 of yacc.c */ #line 23 "parse.y" @@ -728,8 +727,8 @@ ensure_property (void) -/* Line 189 of yacc.c */ -#line 733 "parse.c" +/* Line 268 of yacc.c */ +#line 732 "parse.c" /* Enabling traces. */ #ifndef YYDEBUG @@ -871,7 +870,7 @@ ensure_property (void) typedef union YYSTYPE { -/* Line 214 of yacc.c */ +/* Line 293 of yacc.c */ #line 683 "parse.y" char *id; @@ -882,8 +881,8 @@ typedef union YYSTYPE -/* Line 214 of yacc.c */ -#line 887 "parse.c" +/* Line 293 of yacc.c */ +#line 886 "parse.c" } YYSTYPE; # define YYSTYPE_IS_TRIVIAL 1 # define yystype YYSTYPE /* obsolescent; will be withdrawn */ @@ -894,8 +893,8 @@ typedef union YYSTYPE /* Copy the second part of user declarations. */ -/* Line 264 of yacc.c */ -#line 899 "parse.c" +/* Line 343 of yacc.c */ +#line 898 "parse.c" #ifdef short # undef short @@ -998,11 +997,11 @@ YYID (yyi) # define alloca _alloca # else # define YYSTACK_ALLOC alloca -# if ! defined _ALLOCA_H && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ +# if ! defined _ALLOCA_H && ! defined EXIT_SUCCESS && (defined __STDC__ || defined __C99__FUNC__ \ || defined __cplusplus || defined _MSC_VER) # include /* INFRINGES ON USER NAME SPACE */ -# ifndef _STDLIB_H -# define _STDLIB_H 1 +# ifndef EXIT_SUCCESS +# define EXIT_SUCCESS 0 # endif # endif # endif @@ -1025,24 +1024,24 @@ YYID (yyi) # ifndef YYSTACK_ALLOC_MAXIMUM # define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM # endif -# if (defined __cplusplus && ! defined _STDLIB_H \ +# if (defined __cplusplus && ! defined EXIT_SUCCESS \ && ! ((defined YYMALLOC || defined malloc) \ && (defined YYFREE || defined free))) # include /* INFRINGES ON USER NAME SPACE */ -# ifndef _STDLIB_H -# define _STDLIB_H 1 +# ifndef EXIT_SUCCESS +# define EXIT_SUCCESS 0 # endif # endif # ifndef YYMALLOC # define YYMALLOC malloc -# if ! defined malloc && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ +# if ! defined malloc && ! defined EXIT_SUCCESS && (defined __STDC__ || defined __C99__FUNC__ \ || defined __cplusplus || defined _MSC_VER) void *malloc (YYSIZE_T); /* INFRINGES ON USER NAME SPACE */ # endif # endif # ifndef YYFREE # define YYFREE free -# if ! defined free && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ +# if ! defined free && ! defined EXIT_SUCCESS && (defined __STDC__ || defined __C99__FUNC__ \ || defined __cplusplus || defined _MSC_VER) void free (void *); /* INFRINGES ON USER NAME SPACE */ # endif @@ -1071,23 +1070,7 @@ union yyalloc ((N) * (sizeof (yytype_int16) + sizeof (YYSTYPE)) \ + YYSTACK_GAP_MAXIMUM) -/* Copy COUNT objects from FROM to TO. The source and destination do - not overlap. */ -# ifndef YYCOPY -# if defined __GNUC__ && 1 < __GNUC__ -# define YYCOPY(To, From, Count) \ - __builtin_memcpy (To, From, (Count) * sizeof (*(From))) -# else -# define YYCOPY(To, From, Count) \ - do \ - { \ - YYSIZE_T yyi; \ - for (yyi = 0; yyi < (Count); yyi++) \ - (To)[yyi] = (From)[yyi]; \ - } \ - while (YYID (0)) -# endif -# endif +# define YYCOPY_NEEDED 1 /* Relocate STACK from its old location to the new one. The local variables YYSIZE and YYSTACKSIZE give the old and new number of @@ -1107,6 +1090,26 @@ union yyalloc #endif +#if defined YYCOPY_NEEDED && YYCOPY_NEEDED +/* Copy COUNT objects from FROM to TO. The source and destination do + not overlap. */ +# ifndef YYCOPY +# if defined __GNUC__ && 1 < __GNUC__ +# define YYCOPY(To, From, Count) \ + __builtin_memcpy (To, From, (Count) * sizeof (*(From))) +# else +# define YYCOPY(To, From, Count) \ + do \ + { \ + YYSIZE_T yyi; \ + for (yyi = 0; yyi < (Count); yyi++) \ + (To)[yyi] = (From)[yyi]; \ + } \ + while (YYID (0)) +# endif +# endif +#endif /* !YYCOPY_NEEDED */ + /* YYFINAL -- State number of the termination state. */ #define YYFINAL 25 /* YYLAST -- Last index in YYTABLE. */ @@ -1391,8 +1394,8 @@ static const yytype_uint8 yyr2[] = 1, 7, 8, 3, 1, 1, 2, 1, 1 }; -/* YYDEFACT[STATE-NAME] -- Default rule to reduce with in state - STATE-NUM when YYTABLE doesn't specify something else to do. Zero +/* YYDEFACT[STATE-NAME] -- Default reduction number in state STATE-NUM. + Performed when YYTABLE doesn't specify something else to do. Zero means the default is an error. */ static const yytype_uint8 yydefact[] = { @@ -1513,8 +1516,7 @@ static const yytype_int16 yypgoto[] = /* YYTABLE[YYPACT[STATE-NUM]]. What to do in state STATE-NUM. If positive, shift that token. If negative, reduce the rule which - number is the opposite. If zero, do what YYDEFACT says. - If YYTABLE_NINF, syntax error. */ + number is the opposite. If YYTABLE_NINF, syntax error. */ #define YYTABLE_NINF -160 static const yytype_int16 yytable[] = { @@ -1585,6 +1587,12 @@ static const yytype_int16 yytable[] = 0, 149 }; +#define yypact_value_is_default(yystate) \ + ((yystate) == (-360)) + +#define yytable_value_is_error(yytable_value) \ + YYID (0) + static const yytype_int16 yycheck[] = { 103, 45, 192, 73, 183, 160, 73, 295, 52, 46, @@ -1735,7 +1743,6 @@ do \ { \ yychar = (Token); \ yylval = (Value); \ - yytoken = YYTRANSLATE (yychar); \ YYPOPSTACK (1); \ goto yybackup; \ } \ @@ -1777,19 +1784,10 @@ while (YYID (0)) #endif -/* YY_LOCATION_PRINT -- Print the location on the stream. - This macro was not mandated originally: define only if we know - we won't break user code: when these are the locations we know. */ +/* This macro is provided for backward compatibility. */ #ifndef YY_LOCATION_PRINT -# if defined YYLTYPE_IS_TRIVIAL && YYLTYPE_IS_TRIVIAL -# define YY_LOCATION_PRINT(File, Loc) \ - fprintf (File, "%d.%d-%d.%d", \ - (Loc).first_line, (Loc).first_column, \ - (Loc).last_line, (Loc).last_column) -# else -# define YY_LOCATION_PRINT(File, Loc) ((void) 0) -# endif +# define YY_LOCATION_PRINT(File, Loc) ((void) 0) #endif @@ -1981,7 +1979,6 @@ int yydebug; # define YYMAXDEPTH 10000 #endif - #if YYERROR_VERBOSE @@ -2084,115 +2081,142 @@ yytnamerr (char *yyres, const char *yystr) } # endif -/* Copy into YYRESULT an error message about the unexpected token - YYCHAR while in state YYSTATE. Return the number of bytes copied, - including the terminating null byte. If YYRESULT is null, do not - copy anything; just return the number of bytes that would be - copied. As a special case, return 0 if an ordinary "syntax error" - message will do. Return YYSIZE_MAXIMUM if overflow occurs during - size calculation. */ -static YYSIZE_T -yysyntax_error (char *yyresult, int yystate, int yychar) -{ - int yyn = yypact[yystate]; +/* Copy into *YYMSG, which is of size *YYMSG_ALLOC, an error message + about the unexpected token YYTOKEN for the state stack whose top is + YYSSP. - if (! (YYPACT_NINF < yyn && yyn <= YYLAST)) - return 0; - else - { - int yytype = YYTRANSLATE (yychar); - YYSIZE_T yysize0 = yytnamerr (0, yytname[yytype]); - YYSIZE_T yysize = yysize0; - YYSIZE_T yysize1; - int yysize_overflow = 0; - enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 }; - char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM]; - int yyx; - -# if 0 - /* This is so xgettext sees the translatable formats that are - constructed on the fly. */ - YY_("syntax error, unexpected %s"); - YY_("syntax error, unexpected %s, expecting %s"); - YY_("syntax error, unexpected %s, expecting %s or %s"); - YY_("syntax error, unexpected %s, expecting %s or %s or %s"); - YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s"); -# endif - char *yyfmt; - char const *yyf; - static char const yyunexpected[] = "syntax error, unexpected %s"; - static char const yyexpecting[] = ", expecting %s"; - static char const yyor[] = " or %s"; - char yyformat[sizeof yyunexpected - + sizeof yyexpecting - 1 - + ((YYERROR_VERBOSE_ARGS_MAXIMUM - 2) - * (sizeof yyor - 1))]; - char const *yyprefix = yyexpecting; - - /* Start YYX at -YYN if negative to avoid negative indexes in - YYCHECK. */ - int yyxbegin = yyn < 0 ? -yyn : 0; - - /* Stay within bounds of both yycheck and yytname. */ - int yychecklim = YYLAST - yyn + 1; - int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS; - int yycount = 1; - - yyarg[0] = yytname[yytype]; - yyfmt = yystpcpy (yyformat, yyunexpected); - - for (yyx = yyxbegin; yyx < yyxend; ++yyx) - if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR) - { - if (yycount == YYERROR_VERBOSE_ARGS_MAXIMUM) - { - yycount = 1; - yysize = yysize0; - yyformat[sizeof yyunexpected - 1] = '\0'; - break; - } - yyarg[yycount++] = yytname[yyx]; - yysize1 = yysize + yytnamerr (0, yytname[yyx]); - yysize_overflow |= (yysize1 < yysize); - yysize = yysize1; - yyfmt = yystpcpy (yyfmt, yyprefix); - yyprefix = yyor; - } + Return 0 if *YYMSG was successfully written. Return 1 if *YYMSG is + not large enough to hold the message. In that case, also set + *YYMSG_ALLOC to the required number of bytes. Return 2 if the + required number of bytes is too large to store. */ +static int +yysyntax_error (YYSIZE_T *yymsg_alloc, char **yymsg, + yytype_int16 *yyssp, int yytoken) +{ + YYSIZE_T yysize0 = yytnamerr (0, yytname[yytoken]); + YYSIZE_T yysize = yysize0; + YYSIZE_T yysize1; + enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 }; + /* Internationalized format string. */ + const char *yyformat = 0; + /* Arguments of yyformat. */ + char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM]; + /* Number of reported tokens (one for the "unexpected", one per + "expected"). */ + int yycount = 0; + + /* There are many possibilities here to consider: + - Assume YYFAIL is not used. It's too flawed to consider. See + + for details. YYERROR is fine as it does not invoke this + function. + - If this state is a consistent state with a default action, then + the only way this function was invoked is if the default action + is an error action. In that case, don't check for expected + tokens because there are none. + - The only way there can be no lookahead present (in yychar) is if + this state is a consistent state with a default action. Thus, + detecting the absence of a lookahead is sufficient to determine + that there is no unexpected or expected token to report. In that + case, just report a simple "syntax error". + - Don't assume there isn't a lookahead just because this state is a + consistent state with a default action. There might have been a + previous inconsistent state, consistent state with a non-default + action, or user semantic action that manipulated yychar. + - Of course, the expected token list depends on states to have + correct lookahead information, and it depends on the parser not + to perform extra reductions after fetching a lookahead from the + scanner and before detecting a syntax error. Thus, state merging + (from LALR or IELR) and default reductions corrupt the expected + token list. However, the list is correct for canonical LR with + one exception: it will still contain any token that will not be + accepted due to an error action in a later state. + */ + if (yytoken != YYEMPTY) + { + int yyn = yypact[*yyssp]; + yyarg[yycount++] = yytname[yytoken]; + if (!yypact_value_is_default (yyn)) + { + /* Start YYX at -YYN if negative to avoid negative indexes in + YYCHECK. In other words, skip the first -YYN actions for + this state because they are default actions. */ + int yyxbegin = yyn < 0 ? -yyn : 0; + /* Stay within bounds of both yycheck and yytname. */ + int yychecklim = YYLAST - yyn + 1; + int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS; + int yyx; + + for (yyx = yyxbegin; yyx < yyxend; ++yyx) + if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR + && !yytable_value_is_error (yytable[yyx + yyn])) + { + if (yycount == YYERROR_VERBOSE_ARGS_MAXIMUM) + { + yycount = 1; + yysize = yysize0; + break; + } + yyarg[yycount++] = yytname[yyx]; + yysize1 = yysize + yytnamerr (0, yytname[yyx]); + if (! (yysize <= yysize1 + && yysize1 <= YYSTACK_ALLOC_MAXIMUM)) + return 2; + yysize = yysize1; + } + } + } - yyf = YY_(yyformat); - yysize1 = yysize + yystrlen (yyf); - yysize_overflow |= (yysize1 < yysize); - yysize = yysize1; + switch (yycount) + { +# define YYCASE_(N, S) \ + case N: \ + yyformat = S; \ + break + YYCASE_(0, YY_("syntax error")); + YYCASE_(1, YY_("syntax error, unexpected %s")); + YYCASE_(2, YY_("syntax error, unexpected %s, expecting %s")); + YYCASE_(3, YY_("syntax error, unexpected %s, expecting %s or %s")); + YYCASE_(4, YY_("syntax error, unexpected %s, expecting %s or %s or %s")); + YYCASE_(5, YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s")); +# undef YYCASE_ + } - if (yysize_overflow) - return YYSIZE_MAXIMUM; + yysize1 = yysize + yystrlen (yyformat); + if (! (yysize <= yysize1 && yysize1 <= YYSTACK_ALLOC_MAXIMUM)) + return 2; + yysize = yysize1; - if (yyresult) - { - /* Avoid sprintf, as that infringes on the user's name space. - Don't have undefined behavior even if the translation - produced a string with the wrong number of "%s"s. */ - char *yyp = yyresult; - int yyi = 0; - while ((*yyp = *yyf) != '\0') - { - if (*yyp == '%' && yyf[1] == 's' && yyi < yycount) - { - yyp += yytnamerr (yyp, yyarg[yyi++]); - yyf += 2; - } - else - { - yyp++; - yyf++; - } - } - } - return yysize; + if (*yymsg_alloc < yysize) + { + *yymsg_alloc = 2 * yysize; + if (! (yysize <= *yymsg_alloc + && *yymsg_alloc <= YYSTACK_ALLOC_MAXIMUM)) + *yymsg_alloc = YYSTACK_ALLOC_MAXIMUM; + return 1; } + + /* Avoid sprintf, as that infringes on the user's name space. + Don't have undefined behavior even if the translation + produced a string with the wrong number of "%s"s. */ + { + char *yyp = *yymsg; + int yyi = 0; + while ((*yyp = *yyformat) != '\0') + if (*yyp == '%' && yyformat[1] == 's' && yyi < yycount) + { + yyp += yytnamerr (yyp, yyarg[yyi++]); + yyformat += 2; + } + else + { + yyp++; + yyformat++; + } + } + return 0; } #endif /* YYERROR_VERBOSE */ - /*-----------------------------------------------. | Release the memory associated to this symbol. | @@ -2225,6 +2249,7 @@ yydestruct (yymsg, yytype, yyvaluep) } } + /* Prevent warnings from -Wmissing-prototypes. */ #ifdef YYPARSE_PARAM #if defined __STDC__ || defined __cplusplus @@ -2251,10 +2276,9 @@ YYSTYPE yylval; int yynerrs; - -/*-------------------------. -| yyparse or yypush_parse. | -`-------------------------*/ +/*----------. +| yyparse. | +`----------*/ #ifdef YYPARSE_PARAM #if (defined __STDC__ || defined __C99__FUNC__ \ @@ -2278,8 +2302,6 @@ yyparse () #endif #endif { - - int yystate; /* Number of tokens to shift before error messages enabled. */ int yyerrstatus; @@ -2434,7 +2456,7 @@ yybackup: /* First try to decide what to do without reference to lookahead token. */ yyn = yypact[yystate]; - if (yyn == YYPACT_NINF) + if (yypact_value_is_default (yyn)) goto yydefault; /* Not known => get a lookahead token if don't already have one. */ @@ -2465,8 +2487,8 @@ yybackup: yyn = yytable[yyn]; if (yyn <= 0) { - if (yyn == 0 || yyn == YYTABLE_NINF) - goto yyerrlab; + if (yytable_value_is_error (yyn)) + goto yyerrlab; yyn = -yyn; goto yyreduce; } @@ -2521,35 +2543,35 @@ yyreduce: { case 2: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 704 "parse.y" { ; } break; case 3: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 705 "parse.y" { ; } break; case 4: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 706 "parse.y" { ; } break; case 5: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 707 "parse.y" { ; } break; case 6: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 710 "parse.y" { Node *node = node_new (CCODE_NODE, @@ -2564,7 +2586,7 @@ yyreduce: case 7: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 719 "parse.y" { Node *node = node_new (CCODE_NODE, @@ -2579,7 +2601,7 @@ yyreduce: case 8: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 728 "parse.y" { Node *node = node_new (CCODE_NODE, @@ -2594,7 +2616,7 @@ yyreduce: case 9: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 737 "parse.y" { Node *node = node_new (CCODE_NODE, @@ -2609,7 +2631,7 @@ yyreduce: case 10: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 746 "parse.y" { Node *node = node_new (CCODE_NODE, @@ -2624,7 +2646,7 @@ yyreduce: case 11: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 755 "parse.y" { Node *node = node_new (CCODE_NODE, @@ -2639,7 +2661,7 @@ yyreduce: case 12: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 764 "parse.y" { Node *node = node_new (CCODE_NODE, @@ -2654,7 +2676,7 @@ yyreduce: case 13: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 773 "parse.y" { Node *node = node_new (CCODE_NODE, @@ -2669,63 +2691,63 @@ yyreduce: case 14: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 784 "parse.y" { ; } break; case 15: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 785 "parse.y" { ; } break; case 16: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 786 "parse.y" { ; } break; case 17: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 787 "parse.y" { ; } break; case 18: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 788 "parse.y" { ; } break; case 19: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 789 "parse.y" { ; } break; case 20: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 790 "parse.y" { ; } break; case 21: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 791 "parse.y" { ; } break; case 22: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 794 "parse.y" { ((Class *)class)->nodes = class_nodes; @@ -2736,7 +2758,7 @@ yyreduce: case 23: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 799 "parse.y" { ((Class *)class)->nodes = NULL; @@ -2747,7 +2769,7 @@ yyreduce: case 24: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 806 "parse.y" { class = node_new (CLASS_NODE, @@ -2768,7 +2790,7 @@ yyreduce: case 26: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 824 "parse.y" { if(strcmp((yyvsp[(2) - (4)].id),"abstract") == 0) { @@ -2782,7 +2804,7 @@ yyreduce: case 27: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 832 "parse.y" { if(strcmp((yyvsp[(2) - (5)].id),"chunks") == 0) { @@ -2800,7 +2822,7 @@ yyreduce: case 28: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 844 "parse.y" { if (strcmp ((yyvsp[(2) - (5)].id), "interface") == 0) { @@ -2815,7 +2837,7 @@ yyreduce: case 29: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 853 "parse.y" { if(strcmp((yyvsp[(2) - (5)].id),"chunks") == 0) { @@ -2833,7 +2855,7 @@ yyreduce: case 30: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 865 "parse.y" { if (strcmp ((yyvsp[(2) - (6)].id), "GladeXML") == 0) { @@ -2848,7 +2870,7 @@ yyreduce: case 31: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 874 "parse.y" { if (strcmp ((yyvsp[(2) - (7)].id), "GladeXML") == 0) { @@ -2863,7 +2885,7 @@ yyreduce: case 32: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 883 "parse.y" { if (strcmp ((yyvsp[(2) - (6)].id), "GladeXML") == 0) { @@ -2878,7 +2900,7 @@ yyreduce: case 33: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 892 "parse.y" { if (strcmp ((yyvsp[(2) - (7)].id), "GladeXML") == 0) { @@ -2893,28 +2915,28 @@ yyreduce: case 34: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 903 "parse.y" { ; } break; case 35: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 904 "parse.y" { ; } break; case 36: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 907 "parse.y" { ; } break; case 37: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 908 "parse.y" { if (strcmp ((yyvsp[(1) - (2)].id), "BonoboObject") != 0) { @@ -2929,7 +2951,7 @@ yyreduce: case 38: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 917 "parse.y" { if (strcmp ((yyvsp[(1) - (3)].id), "interface") != 0) { @@ -2947,63 +2969,63 @@ yyreduce: case 39: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 929 "parse.y" { ; } break; case 40: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 930 "parse.y" { ; } break; case 41: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 931 "parse.y" { ; } break; case 42: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 932 "parse.y" { ; } break; case 43: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 935 "parse.y" { the_scope = PUBLIC_SCOPE; } break; case 44: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 936 "parse.y" { the_scope = PRIVATE_SCOPE; } break; case 45: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 937 "parse.y" { the_scope = PROTECTED_SCOPE; } break; case 46: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 938 "parse.y" { the_scope = CLASS_SCOPE; } break; case 47: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 941 "parse.y" { if (strcmp ((yyvsp[(1) - (2)].id), "destroywith") == 0) { @@ -3029,7 +3051,7 @@ yyreduce: case 48: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 961 "parse.y" { if (strcmp ((yyvsp[(1) - (3)].id), "destroy") == 0) { @@ -3057,7 +3079,7 @@ yyreduce: case 49: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 985 "parse.y" { initializer = (yyvsp[(2) - (2)].id); @@ -3067,7 +3089,7 @@ yyreduce: case 50: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 989 "parse.y" { initializer = ((yyvsp[(3) - (3)].cbuf))->str; @@ -3078,35 +3100,35 @@ yyreduce: case 51: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 997 "parse.y" { ; } break; case 52: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 998 "parse.y" { ; } break; case 53: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 999 "parse.y" { destructor = NULL; } break; case 54: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1000 "parse.y" { initializer = NULL; } break; case 55: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1001 "parse.y" { if (strcmp ((yyvsp[(1) - (1)].id), "GladeXML") == 0) { @@ -3120,7 +3142,7 @@ yyreduce: case 56: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1009 "parse.y" { destructor = NULL; @@ -3130,7 +3152,7 @@ yyreduce: case 57: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1015 "parse.y" { push_variable((yyvsp[(3) - (5)].id), the_scope,(yyvsp[(1) - (5)].line), NULL); @@ -3139,7 +3161,7 @@ yyreduce: case 58: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1018 "parse.y" { push_variable((yyvsp[(3) - (6)].id), the_scope, (yyvsp[(1) - (6)].line), (yyvsp[(4) - (6)].id)); @@ -3148,7 +3170,7 @@ yyreduce: case 59: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1023 "parse.y" { Node *node = NULL; @@ -3222,7 +3244,7 @@ yyreduce: case 60: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1091 "parse.y" { Node *node = NULL; @@ -3282,7 +3304,7 @@ yyreduce: case 61: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1145 "parse.y" { Node *node; @@ -3375,7 +3397,7 @@ yyreduce: case 62: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1234 "parse.y" { if (strcmp ((yyvsp[(2) - (3)].id), "export")!=0) { @@ -3389,7 +3411,7 @@ yyreduce: case 63: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1242 "parse.y" { (yyval.id) = NULL; @@ -3398,7 +3420,7 @@ yyreduce: case 64: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1247 "parse.y" { ensure_property (); @@ -3452,7 +3474,7 @@ yyreduce: case 65: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1295 "parse.y" { ensure_property (); @@ -3494,7 +3516,7 @@ yyreduce: case 66: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1331 "parse.y" { ensure_property (); @@ -3514,42 +3536,42 @@ yyreduce: case 67: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1347 "parse.y" { ; } break; case 68: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1348 "parse.y" { ; } break; case 69: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1351 "parse.y" { ; } break; case 70: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1352 "parse.y" { ; } break; case 71: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1355 "parse.y" { (yyval.id) = (yyvsp[(1) - (1)].id); } break; case 72: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1356 "parse.y" { if (strcmp ((yyvsp[(1) - (4)].id), "_") != 0) { @@ -3565,21 +3587,21 @@ yyreduce: case 73: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1368 "parse.y" { (yyval.id) = (yyvsp[(1) - (1)].id); } break; case 74: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1369 "parse.y" { (yyval.id) = (yyvsp[(1) - (1)].id); } break; case 75: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1372 "parse.y" { ensure_property (); @@ -3591,7 +3613,7 @@ yyreduce: case 76: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1378 "parse.y" { ensure_property (); @@ -3603,7 +3625,7 @@ yyreduce: case 77: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1384 "parse.y" { ensure_property (); @@ -3615,7 +3637,7 @@ yyreduce: case 78: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1390 "parse.y" { ensure_property (); @@ -3627,7 +3649,7 @@ yyreduce: case 79: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1396 "parse.y" { ensure_property (); @@ -3639,7 +3661,7 @@ yyreduce: case 80: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1402 "parse.y" { ensure_property (); @@ -3651,7 +3673,7 @@ yyreduce: case 81: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1408 "parse.y" { Type *type = pop_type (); @@ -3664,7 +3686,7 @@ yyreduce: case 82: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1415 "parse.y" { ensure_property (); @@ -3676,7 +3698,7 @@ yyreduce: case 83: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1421 "parse.y" { ensure_property (); @@ -3688,7 +3710,7 @@ yyreduce: case 84: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1427 "parse.y" { ensure_property (); @@ -3700,7 +3722,7 @@ yyreduce: case 85: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1433 "parse.y" { ensure_property (); @@ -3712,7 +3734,7 @@ yyreduce: case 86: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1439 "parse.y" { ensure_property (); @@ -3724,7 +3746,7 @@ yyreduce: case 87: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1445 "parse.y" { ensure_property (); @@ -3736,7 +3758,7 @@ yyreduce: case 88: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1451 "parse.y" { ensure_property (); @@ -3748,7 +3770,7 @@ yyreduce: case 89: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1457 "parse.y" { ensure_property (); @@ -3760,7 +3782,7 @@ yyreduce: case 90: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1463 "parse.y" { ensure_property (); @@ -3772,7 +3794,7 @@ yyreduce: case 91: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1469 "parse.y" { ensure_property (); @@ -3784,7 +3806,7 @@ yyreduce: case 92: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1475 "parse.y" { ensure_property (); @@ -3813,7 +3835,7 @@ yyreduce: case 93: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1500 "parse.y" { if(strcmp((yyvsp[(3) - (5)].id),"type")!=0) { @@ -3828,7 +3850,7 @@ yyreduce: case 94: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1509 "parse.y" { (yyval.id) = debool ((yyvsp[(1) - (1)].id)); @@ -3838,21 +3860,21 @@ yyreduce: case 95: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1515 "parse.y" { (yyval.list) = (yyvsp[(2) - (3)].list); } break; case 96: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1516 "parse.y" { (yyval.list) = NULL; } break; case 97: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1519 "parse.y" { (yyval.list) = g_list_append((yyvsp[(3) - (3)].list),(yyvsp[(1) - (3)].id)); @@ -3861,7 +3883,7 @@ yyreduce: case 98: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1522 "parse.y" { (yyval.list) = g_list_append(NULL,(yyvsp[(1) - (1)].id)); @@ -3870,7 +3892,7 @@ yyreduce: case 99: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1528 "parse.y" { Node *node = node_new (TYPE_NODE, @@ -3883,7 +3905,7 @@ yyreduce: case 100: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1535 "parse.y" { Node *node = node_new (TYPE_NODE, @@ -3895,7 +3917,7 @@ yyreduce: case 101: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1544 "parse.y" { (yyval.id) = (yyvsp[(1) - (1)].id); @@ -3904,7 +3926,7 @@ yyreduce: case 102: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1547 "parse.y" { (yyval.id) = (yyvsp[(1) - (1)].id); @@ -3913,7 +3935,7 @@ yyreduce: case 103: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1550 "parse.y" { (yyval.id) = g_strconcat("const ", (yyvsp[(2) - (2)].id), NULL); @@ -3923,7 +3945,7 @@ yyreduce: case 104: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1554 "parse.y" { (yyval.id) = g_strconcat((yyvsp[(1) - (2)].id), " const", NULL); @@ -3933,7 +3955,7 @@ yyreduce: case 105: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1558 "parse.y" { (yyval.id) = g_strconcat((yyvsp[(1) - (2)].id), " ", (yyvsp[(2) - (2)].id), NULL); @@ -3943,7 +3965,7 @@ yyreduce: case 106: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1562 "parse.y" { (yyval.id) = g_strconcat("const ", (yyvsp[(2) - (3)].id), " ", @@ -3954,7 +3976,7 @@ yyreduce: case 107: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1567 "parse.y" { (yyval.id) = g_strconcat((yyvsp[(1) - (3)].id), " ", @@ -3965,7 +3987,7 @@ yyreduce: case 108: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1575 "parse.y" { (yyval.id) = g_strconcat((yyvsp[(1) - (2)].id), " ", (yyvsp[(2) - (2)].id), NULL); @@ -3975,7 +3997,7 @@ yyreduce: case 109: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1579 "parse.y" { (yyval.id) = g_strconcat((yyvsp[(1) - (2)].id), " ", (yyvsp[(2) - (2)].id), NULL); @@ -3986,7 +4008,7 @@ yyreduce: case 110: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1584 "parse.y" { (yyval.id) = g_strconcat("const ", (yyvsp[(2) - (2)].id), NULL); @@ -3996,7 +4018,7 @@ yyreduce: case 111: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1588 "parse.y" { (yyval.id) = (yyvsp[(1) - (1)].id); @@ -4005,7 +4027,7 @@ yyreduce: case 112: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1591 "parse.y" { (yyval.id) = g_strconcat((yyvsp[(1) - (2)].id), " const", NULL); @@ -4015,7 +4037,7 @@ yyreduce: case 113: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1595 "parse.y" { (yyval.id) = g_strdup((yyvsp[(1) - (1)].id)); @@ -4024,7 +4046,7 @@ yyreduce: case 114: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1598 "parse.y" { (yyval.id) = g_strconcat((yyvsp[(1) - (2)].id), " const", NULL); @@ -4033,105 +4055,105 @@ yyreduce: case 115: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1603 "parse.y" { (yyval.id) = "void"; } break; case 116: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1604 "parse.y" { (yyval.id) = "char"; } break; case 117: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1605 "parse.y" { (yyval.id) = "short"; } break; case 118: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1606 "parse.y" { (yyval.id) = "int"; } break; case 119: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1607 "parse.y" { (yyval.id) = "long"; } break; case 120: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1608 "parse.y" { (yyval.id) = "float"; } break; case 121: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1609 "parse.y" { (yyval.id) = "double"; } break; case 122: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1610 "parse.y" { (yyval.id) = "signed"; } break; case 123: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1611 "parse.y" { (yyval.id) = "unsigned"; } break; case 124: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1614 "parse.y" { (yyval.id) = "struct"; } break; case 125: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1615 "parse.y" { (yyval.id) = "union"; } break; case 126: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1616 "parse.y" { (yyval.id) = "enum"; } break; case 127: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1619 "parse.y" { (yyval.id) = g_strdup("*"); } break; case 128: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1620 "parse.y" { (yyval.id) = g_strdup("* const"); } break; case 129: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1621 "parse.y" { (yyval.id) = g_strconcat("*", (yyvsp[(2) - (2)].id), NULL); @@ -4141,7 +4163,7 @@ yyreduce: case 130: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1625 "parse.y" { (yyval.id) = g_strconcat("* const", (yyvsp[(3) - (3)].id), NULL); @@ -4151,7 +4173,7 @@ yyreduce: case 131: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1632 "parse.y" { if(strcmp((yyvsp[(1) - (2)].id), "first")==0) @@ -4169,7 +4191,7 @@ yyreduce: case 132: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1644 "parse.y" { (yyval.sigtype) = SIGNAL_LAST_METHOD; @@ -4178,7 +4200,7 @@ yyreduce: case 133: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1650 "parse.y" { if(strcmp((yyvsp[(2) - (3)].id),"first")==0) @@ -4196,7 +4218,7 @@ yyreduce: case 134: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1662 "parse.y" { if(strcmp((yyvsp[(1) - (3)].id),"first")==0) @@ -4214,7 +4236,7 @@ yyreduce: case 135: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1674 "parse.y" { (yyval.sigtype) = SIGNAL_LAST_METHOD; @@ -4223,7 +4245,7 @@ yyreduce: case 136: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1677 "parse.y" { /* the_scope was default thus public */ @@ -4233,7 +4255,7 @@ yyreduce: case 137: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1683 "parse.y" { gtktypes = g_list_prepend(gtktypes, debool ((yyvsp[(1) - (4)].id))); @@ -4242,7 +4264,7 @@ yyreduce: case 138: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1688 "parse.y" { gtktypes = g_list_append(gtktypes, debool ((yyvsp[(3) - (3)].id))); @@ -4251,7 +4273,7 @@ yyreduce: case 139: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1691 "parse.y" { gtktypes = g_list_append(gtktypes, debool ((yyvsp[(1) - (1)].id))); @@ -4260,21 +4282,21 @@ yyreduce: case 140: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1696 "parse.y" { (yyval.cbuf) = (yyvsp[(2) - (2)].cbuf); } break; case 141: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1697 "parse.y" { (yyval.cbuf) = NULL; } break; case 142: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1701 "parse.y" { if(!has_self) { @@ -4303,7 +4325,7 @@ yyreduce: case 143: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1724 "parse.y" { if(!has_self) { @@ -4332,7 +4354,7 @@ yyreduce: case 144: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1747 "parse.y" { if(!has_self) { @@ -4361,7 +4383,7 @@ yyreduce: case 145: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1770 "parse.y" { if(!has_self) { @@ -4390,7 +4412,7 @@ yyreduce: case 146: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1793 "parse.y" { if(!has_self) { @@ -4414,7 +4436,7 @@ yyreduce: case 147: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1811 "parse.y" { if (funcattrs != NULL) { @@ -4433,7 +4455,7 @@ yyreduce: case 148: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1824 "parse.y" { if(the_scope == CLASS_SCOPE) { @@ -4449,7 +4471,7 @@ yyreduce: case 149: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1834 "parse.y" { if(strcmp((yyvsp[(1) - (5)].id), "init")==0) { @@ -4493,7 +4515,7 @@ yyreduce: case 150: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1874 "parse.y" { g_free(funcattrs); funcattrs = NULL; @@ -4511,7 +4533,7 @@ yyreduce: case 151: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1886 "parse.y" { g_free(funcattrs); funcattrs = NULL; @@ -4537,7 +4559,7 @@ yyreduce: case 152: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1906 "parse.y" { g_free(funcattrs); funcattrs = NULL; @@ -4574,7 +4596,7 @@ yyreduce: case 153: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1937 "parse.y" { g_free(funcattrs); funcattrs = NULL; @@ -4585,14 +4607,14 @@ yyreduce: case 154: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1944 "parse.y" { (yyval.id) = (yyvsp[(1) - (1)].id); } break; case 155: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1945 "parse.y" { (yyval.id) = ((yyvsp[(2) - (2)].cbuf))->str; @@ -4602,14 +4624,14 @@ yyreduce: case 156: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1951 "parse.y" { vararg = FALSE; has_self = FALSE; } break; case 157: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1952 "parse.y" { vararg = FALSE; @@ -4626,7 +4648,7 @@ yyreduce: case 158: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1963 "parse.y" { vararg = FALSE; @@ -4643,7 +4665,7 @@ yyreduce: case 159: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1974 "parse.y" { vararg = FALSE; @@ -4660,7 +4682,7 @@ yyreduce: case 160: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1985 "parse.y" { has_self = TRUE; @@ -4676,7 +4698,7 @@ yyreduce: case 161: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 1995 "parse.y" { has_self = TRUE; @@ -4692,7 +4714,7 @@ yyreduce: case 162: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 2005 "parse.y" { has_self = TRUE; @@ -4708,42 +4730,42 @@ yyreduce: case 163: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 2015 "parse.y" { has_self = FALSE; } break; case 164: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 2018 "parse.y" { vararg = TRUE; } break; case 165: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 2019 "parse.y" { vararg = FALSE; } break; case 166: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 2022 "parse.y" { ; } break; case 167: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 2023 "parse.y" { ; } break; case 168: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 2026 "parse.y" { push_funcarg((yyvsp[(2) - (2)].id),NULL); @@ -4752,7 +4774,7 @@ yyreduce: case 169: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 2029 "parse.y" { push_funcarg((yyvsp[(2) - (3)].id),(yyvsp[(3) - (3)].id)); @@ -4761,7 +4783,7 @@ yyreduce: case 170: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 2032 "parse.y" { if(strcmp((yyvsp[(4) - (6)].id),"check")!=0) { @@ -4775,7 +4797,7 @@ yyreduce: case 171: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 2040 "parse.y" { if(strcmp((yyvsp[(5) - (7)].id),"check")!=0) { @@ -4789,21 +4811,21 @@ yyreduce: case 172: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 2050 "parse.y" { ; } break; case 173: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 2051 "parse.y" { ; } break; case 174: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 2054 "parse.y" { if(strcmp((yyvsp[(1) - (1)].id),"type")==0) { @@ -4826,7 +4848,7 @@ yyreduce: case 175: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 2071 "parse.y" { Node *node = node_new (CHECK_NODE, @@ -4839,7 +4861,7 @@ yyreduce: case 176: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 2078 "parse.y" { Node *node = node_new (CHECK_NODE, @@ -4852,7 +4874,7 @@ yyreduce: case 177: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 2085 "parse.y" { Node *node = node_new (CHECK_NODE, @@ -4865,7 +4887,7 @@ yyreduce: case 178: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 2092 "parse.y" { Node *node = node_new (CHECK_NODE, @@ -4878,7 +4900,7 @@ yyreduce: case 179: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 2099 "parse.y" { Node *node = node_new (CHECK_NODE, @@ -4891,7 +4913,7 @@ yyreduce: case 180: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 2106 "parse.y" { Node *node = node_new (CHECK_NODE, @@ -4904,7 +4926,7 @@ yyreduce: case 181: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 2115 "parse.y" { Node *node = node_new (ENUMDEF_NODE, @@ -4919,7 +4941,7 @@ yyreduce: case 182: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 2124 "parse.y" { Node *node = node_new (ENUMDEF_NODE, @@ -4934,21 +4956,21 @@ yyreduce: case 183: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 2135 "parse.y" {;} break; case 184: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 2136 "parse.y" {;} break; case 185: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 2139 "parse.y" { Node *node; @@ -4974,7 +4996,7 @@ yyreduce: case 186: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 2159 "parse.y" { Node *node; @@ -4988,7 +5010,7 @@ yyreduce: case 187: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 2169 "parse.y" { Node *node = node_new (FLAGS_NODE, @@ -5003,7 +5025,7 @@ yyreduce: case 188: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 2178 "parse.y" { Node *node = node_new (FLAGS_NODE, @@ -5018,7 +5040,7 @@ yyreduce: case 189: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 2189 "parse.y" { flag_vals = g_list_append (flag_vals, (yyvsp[(3) - (3)].id)); @@ -5027,7 +5049,7 @@ yyreduce: case 190: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 2192 "parse.y" { flag_vals = g_list_append (flag_vals, (yyvsp[(1) - (1)].id)); @@ -5036,7 +5058,7 @@ yyreduce: case 191: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 2197 "parse.y" { Node *node = node_new (ERROR_NODE, @@ -5051,7 +5073,7 @@ yyreduce: case 192: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 2206 "parse.y" { Node *node = node_new (ERROR_NODE, @@ -5066,7 +5088,7 @@ yyreduce: case 193: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 2217 "parse.y" { error_vals = g_list_append (error_vals, (yyvsp[(3) - (3)].id)); @@ -5075,7 +5097,7 @@ yyreduce: case 194: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 2220 "parse.y" { error_vals = g_list_append (error_vals, (yyvsp[(1) - (1)].id)); @@ -5084,14 +5106,14 @@ yyreduce: case 195: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 2226 "parse.y" { (yyval.id) = (yyvsp[(1) - (1)].id); } break; case 196: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 2227 "parse.y" { (yyval.id) = g_strconcat("-",(yyvsp[(2) - (2)].id),NULL); @@ -5101,24 +5123,35 @@ yyreduce: case 197: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 2231 "parse.y" { (yyval.id) = (yyvsp[(1) - (1)].id); } break; case 198: -/* Line 1464 of yacc.c */ +/* Line 1806 of yacc.c */ #line 2232 "parse.y" { (yyval.id) = (yyvsp[(1) - (1)].id); } break; -/* Line 1464 of yacc.c */ -#line 5120 "parse.c" +/* Line 1806 of yacc.c */ +#line 5142 "parse.c" default: break; } + /* User semantic actions sometimes alter yychar, and that requires + that yytoken be updated with the new translation. We take the + approach of translating immediately before every use of yytoken. + One alternative is translating here after every semantic action, + but that translation would be missed if the semantic action invokes + YYABORT, YYACCEPT, or YYERROR immediately after altering yychar or + if it invokes YYBACKUP. In the case of YYABORT or YYACCEPT, an + incorrect destructor might then be invoked immediately. In the + case of YYERROR or YYBACKUP, subsequent parser actions might lead + to an incorrect destructor call or verbose syntax error message + before the lookahead is translated. */ YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc); YYPOPSTACK (yylen); @@ -5146,6 +5179,10 @@ yyreduce: | yyerrlab -- here on detecting error | `------------------------------------*/ yyerrlab: + /* Make sure we have latest lookahead translation. See comments at + user semantic actions for why this is necessary. */ + yytoken = yychar == YYEMPTY ? YYEMPTY : YYTRANSLATE (yychar); + /* If not already recovering from an error, report this error. */ if (!yyerrstatus) { @@ -5153,37 +5190,36 @@ yyerrlab: #if ! YYERROR_VERBOSE yyerror (YY_("syntax error")); #else +# define YYSYNTAX_ERROR yysyntax_error (&yymsg_alloc, &yymsg, \ + yyssp, yytoken) { - YYSIZE_T yysize = yysyntax_error (0, yystate, yychar); - if (yymsg_alloc < yysize && yymsg_alloc < YYSTACK_ALLOC_MAXIMUM) - { - YYSIZE_T yyalloc = 2 * yysize; - if (! (yysize <= yyalloc && yyalloc <= YYSTACK_ALLOC_MAXIMUM)) - yyalloc = YYSTACK_ALLOC_MAXIMUM; - if (yymsg != yymsgbuf) - YYSTACK_FREE (yymsg); - yymsg = (char *) YYSTACK_ALLOC (yyalloc); - if (yymsg) - yymsg_alloc = yyalloc; - else - { - yymsg = yymsgbuf; - yymsg_alloc = sizeof yymsgbuf; - } - } - - if (0 < yysize && yysize <= yymsg_alloc) - { - (void) yysyntax_error (yymsg, yystate, yychar); - yyerror (yymsg); - } - else - { - yyerror (YY_("syntax error")); - if (yysize != 0) - goto yyexhaustedlab; - } + char const *yymsgp = YY_("syntax error"); + int yysyntax_error_status; + yysyntax_error_status = YYSYNTAX_ERROR; + if (yysyntax_error_status == 0) + yymsgp = yymsg; + else if (yysyntax_error_status == 1) + { + if (yymsg != yymsgbuf) + YYSTACK_FREE (yymsg); + yymsg = (char *) YYSTACK_ALLOC (yymsg_alloc); + if (!yymsg) + { + yymsg = yymsgbuf; + yymsg_alloc = sizeof yymsgbuf; + yysyntax_error_status = 2; + } + else + { + yysyntax_error_status = YYSYNTAX_ERROR; + yymsgp = yymsg; + } + } + yyerror (yymsgp); + if (yysyntax_error_status == 2) + goto yyexhaustedlab; } +# undef YYSYNTAX_ERROR #endif } @@ -5242,7 +5278,7 @@ yyerrlab1: for (;;) { yyn = yypact[yystate]; - if (yyn != YYPACT_NINF) + if (!yypact_value_is_default (yyn)) { yyn += YYTERROR; if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYTERROR) @@ -5301,8 +5337,13 @@ yyexhaustedlab: yyreturn: if (yychar != YYEMPTY) - yydestruct ("Cleanup: discarding lookahead", - yytoken, &yylval); + { + /* Make sure we have latest lookahead translation. See comments at + user semantic actions for why this is necessary. */ + yytoken = YYTRANSLATE (yychar); + yydestruct ("Cleanup: discarding lookahead", + yytoken, &yylval); + } /* Do not reclaim the symbols of the rule which action triggered this YYABORT or YYACCEPT. */ YYPOPSTACK (yylen); @@ -5327,7 +5368,7 @@ yyreturn: -/* Line 1684 of yacc.c */ +/* Line 2067 of yacc.c */ #line 2235 "parse.y"