1 /* A Bison parser, made from parse-gram.y, by GNU bison 1.75a.  */ 
   3 /* Skeleton parser for Yacc-like parsing with Bison, 
   4    Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002 Free Software Foundation, Inc. 
   6    This program is free software; you can redistribute it and/or modify 
   7    it under the terms of the GNU General Public License as published by 
   8    the Free Software Foundation; either version 2, or (at your option) 
  11    This program is distributed in the hope that it will be useful, 
  12    but WITHOUT ANY WARRANTY; without even the implied warranty of 
  13    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the 
  14    GNU General Public License for more details. 
  16    You should have received a copy of the GNU General Public License 
  17    along with this program; if not, write to the Free Software 
  18    Foundation, Inc., 59 Temple Place - Suite 330, 
  19    Boston, MA 02111-1307, USA.  */ 
  21 /* As a special exception, when this file is copied by Bison into a 
  22    Bison output file, you may use that output file without restriction. 
  23    This special exception was added by the Free Software Foundation 
  24    in version 1.24 of Bison.  */ 
  26 /* Written by Richard Stallman by simplifying the original so called 
  27    ``semantic'' parser.  */ 
  29 /* All symbols defined below should begin with yy or YY, to avoid 
  30    infringing on user name space.  This should be done even for local 
  31    variables, as they might otherwise be expanded by user macros. 
  32    There are some unavoidable exceptions within include files to 
  33    define necessary library symbols; they are noted "INFRINGES ON 
  34    USER NAME SPACE" below.  */ 
  36 /* Identify Bison output.  */ 
  42 /* Using locations.  */ 
  43 #define YYLSP_NEEDED 1 
  45 /* If NAME_PREFIX is specified substitute the variables and functions 
  47 #define yyparse gram_parse 
  48 #define yylex   gram_lex 
  49 #define yyerror gram_error 
  50 #define yylval  gram_lval 
  51 #define yychar  gram_char 
  52 #define yydebug gram_debug 
  53 #define yynerrs gram_nerrs 
  54 #define yylloc gram_lloc 
  59    /* Put the tokens into the symbol table, so that GDB and other debuggers 
  69      PERCENT_DESTRUCTOR 
= 264, 
  70      PERCENT_PRINTER 
= 265, 
  74      PERCENT_NONASSOC 
= 269, 
  80      PERCENT_DEFINES 
= 275, 
  81      PERCENT_ERROR_VERBOSE 
= 276, 
  83      PERCENT_FILE_PREFIX 
= 278, 
  84      PERCENT_GLR_PARSER 
= 279, 
  85      PERCENT_LEX_PARAM 
= 280, 
  86      PERCENT_LOCATIONS 
= 281, 
  87      PERCENT_NAME_PREFIX 
= 282, 
  88      PERCENT_NO_LINES 
= 283, 
  90      PERCENT_PARSE_PARAM 
= 285, 
  91      PERCENT_PURE_PARSER 
= 286, 
  92      PERCENT_SKELETON 
= 287, 
  94      PERCENT_TOKEN_TABLE 
= 289, 
  95      PERCENT_VERBOSE 
= 290, 
 104      PERCENT_PERCENT 
= 299, 
 112 #define CHARACTER 259 
 114 #define PERCENT_TOKEN 261 
 115 #define PERCENT_NTERM 262 
 116 #define PERCENT_TYPE 263 
 117 #define PERCENT_DESTRUCTOR 264 
 118 #define PERCENT_PRINTER 265 
 119 #define PERCENT_UNION 266 
 120 #define PERCENT_LEFT 267 
 121 #define PERCENT_RIGHT 268 
 122 #define PERCENT_NONASSOC 269 
 123 #define PERCENT_PREC 270 
 124 #define PERCENT_DPREC 271 
 125 #define PERCENT_MERGE 272 
 126 #define PERCENT_DEBUG 273 
 127 #define PERCENT_DEFINE 274 
 128 #define PERCENT_DEFINES 275 
 129 #define PERCENT_ERROR_VERBOSE 276 
 130 #define PERCENT_EXPECT 277 
 131 #define PERCENT_FILE_PREFIX 278 
 132 #define PERCENT_GLR_PARSER 279 
 133 #define PERCENT_LEX_PARAM 280 
 134 #define PERCENT_LOCATIONS 281 
 135 #define PERCENT_NAME_PREFIX 282 
 136 #define PERCENT_NO_LINES 283 
 137 #define PERCENT_OUTPUT 284 
 138 #define PERCENT_PARSE_PARAM 285 
 139 #define PERCENT_PURE_PARSER 286 
 140 #define PERCENT_SKELETON 287 
 141 #define PERCENT_START 288 
 142 #define PERCENT_TOKEN_TABLE 289 
 143 #define PERCENT_VERBOSE 290 
 144 #define PERCENT_YACC 291 
 147 #define SEMICOLON 294 
 152 #define PERCENT_PERCENT 299 
 155 #define BRACED_CODE 302 
 160 /* Copy the first part of user declarations.  */ 
 161 #line 31 "parse-gram.y" 
 164 #include "complain.h" 
 165 #include "muscle_tab.h" 
 172 #include "conflicts.h" 
 174 /* Produce verbose parse errors.  */ 
 175 #define YYERROR_VERBOSE 1 
 176 #define YYLLOC_DEFAULT(Current, Rhs, N)                 \ 
 180     Current.first_column  = Rhs[1].first_column;        \ 
 181     Current.first_line    = Rhs[1].first_line;          \ 
 182     Current.last_column   = Rhs[N].last_column;         \ 
 183     Current.last_line     = Rhs[N].last_line;           \ 
 191 /* Pass the control structure to YYPARSE and YYLEX. */ 
 192 #define YYPARSE_PARAM gram_control 
 193 #define YYLEX_PARAM gram_control 
 194 /* YYPARSE receives GRAM_CONTROL as a void *.  Provide a 
 195    correctly typed access to it.  */ 
 196 #define yycontrol ((gram_control_t *) gram_control) 
 198 /* Request detailed parse error messages, and pass them to GRAM_ERROR. 
 199    FIXME: depends on the undocumented availability of YYLLOC.t */ 
 201 #define yyerror(Msg) \ 
 202         gram_error (&yylloc, Msg) 
 204 #define YYPRINT(File, Type, Value) \ 
 205         yyprint (File, Type, &Value) 
 206 static void yyprint (FILE *file
, int type
, const yystype 
*value
); 
 208 symbol_class current_class 
= unknown_sym
; 
 209 char *current_type 
= 0; 
 210 symbol_t 
*current_lhs
; 
 211 location_t current_lhs_location
; 
 212 assoc_t current_assoc
; 
 213 int current_prec 
= 0; 
 214 braced_code_t current_braced_code 
= action_braced_code
; 
 217 /* Enabling traces.  */ 
 222 /* Enabling verbose error messages.  */ 
 223 #ifdef YYERROR_VERBOSE 
 224 # undef YYERROR_VERBOSE 
 225 # define YYERROR_VERBOSE 1 
 227 # define YYERROR_VERBOSE 0 
 231 #line 89 "parse-gram.y" 
 239 /* Line 203 of /tmp/prefix/share/bison/yacc.c.  */ 
 240 #line 241 "parse-gram.c" 
 241 # define YYSTYPE yystype 
 242 # define YYSTYPE_IS_TRIVIAL 1 
 246 typedef struct yyltype
 
 253 # define YYLTYPE yyltype 
 254 # define YYLTYPE_IS_TRIVIAL 1 
 257 /* Copy the second part of user declarations.  */ 
 260 /* Line 223 of /tmp/prefix/share/bison/yacc.c.  */ 
 261 #line 262 "parse-gram.c" 
 263 #if ! defined (yyoverflow) || YYERROR_VERBOSE 
 265 /* The parser invokes alloca or malloc; define the necessary symbols.  */ 
 267 # if YYSTACK_USE_ALLOCA 
 268 #  define YYSTACK_ALLOC alloca 
 270 #  ifndef YYSTACK_USE_ALLOCA 
 271 #   if defined (alloca) || defined (_ALLOCA_H) 
 272 #    define YYSTACK_ALLOC alloca 
 275 #     define YYSTACK_ALLOC __builtin_alloca 
 281 # ifdef YYSTACK_ALLOC 
 282    /* Pacify GCC's `empty if-body' warning. */ 
 283 #  define YYSTACK_FREE(Ptr) do { /* empty */; } while (0) 
 285 #  if defined (__STDC__) || defined (__cplusplus) 
 286 #   include <stdlib.h> /* INFRINGES ON USER NAME SPACE */ 
 287 #   define YYSIZE_T size_t 
 289 #  define YYSTACK_ALLOC malloc 
 290 #  define YYSTACK_FREE free 
 292 #endif /* ! defined (yyoverflow) || YYERROR_VERBOSE */ 
 295 #if (! defined (yyoverflow) \ 
 296      && (! defined (__cplusplus) \ 
 297          || (YYLTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL))) 
 299 /* A type that is properly aligned for any stack member.  */ 
 307 /* The size of the maximum gap between one aligned stack and the next.  */ 
 308 # define YYSTACK_GAP_MAX (sizeof (union yyalloc) - 1) 
 310 /* The size of an array large to enough to hold all stacks, each with 
 312 # define YYSTACK_BYTES(N) \ 
 313      ((N) * (sizeof (short) + sizeof (YYSTYPE) + sizeof (YYLTYPE))      \ 
 314       + 2 * YYSTACK_GAP_MAX) 
 316 /* Copy COUNT objects from FROM to TO.  The source and destination do 
 320 #   define YYCOPY(To, From, Count) \ 
 321       __builtin_memcpy (To, From, (Count) * sizeof (*(From))) 
 323 #   define YYCOPY(To, From, Count)              \ 
 326           register YYSIZE_T yyi;                \ 
 327           for (yyi = 0; yyi < (Count); yyi++)   \ 
 328             (To)[yyi] = (From)[yyi];    \ 
 334 /* Relocate STACK from its old location to the new one.  The 
 335    local variables YYSIZE and YYSTACKSIZE give the old and new number of 
 336    elements in the stack, and YYPTR gives the new location of the 
 337    stack.  Advance YYPTR to a properly aligned location for the next 
 339 # define YYSTACK_RELOCATE(Stack)                                        \ 
 342         YYSIZE_T yynewbytes;                                            \ 
 343         YYCOPY (&yyptr->Stack, Stack, yysize);                          \ 
 344         Stack = &yyptr->Stack;                                          \ 
 345         yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAX;   \ 
 346         yyptr += yynewbytes / sizeof (*yyptr);                          \ 
 352 #if defined (__STDC__) || defined (__cplusplus) 
 353    typedef signed char yysigned_char
; 
 355    typedef short yysigned_char
; 
 358 /* YYFINAL -- State number of the termination state. */ 
 360 /* YYLAST -- Last index in YYTABLE.  */ 
 363 /* YYNTOKENS -- Number of terminals. */ 
 365 /* YYNNTS -- Number of nonterminals. */ 
 367 /* YYNRULES -- Number of rules. */ 
 369 /* YYNRULES -- Number of states. */ 
 370 #define YYNSTATES  116 
 372 /* YYTRANSLATE(YYLEX) -- Bison symbol number corresponding to YYLEX.  */ 
 374 #define YYMAXUTOK   302 
 376 #define YYTRANSLATE(X) \ 
 377   ((unsigned)(X) <= YYMAXUTOK ? yytranslate[X] : YYUNDEFTOK) 
 379 /* YYTRANSLATE[YYLEX] -- Bison symbol number corresponding to YYLEX.  */ 
 380 static const unsigned char yytranslate
[] = 
 382        0,     2,     2,     2,     2,     2,     2,     2,     2,     2, 
 383        2,     2,     2,     2,     2,     2,     2,     2,     2,     2, 
 384        2,     2,     2,     2,     2,     2,     2,     2,     2,     2, 
 385        2,     2,     2,     2,     2,     2,     2,     2,     2,     2, 
 386        2,     2,     2,     2,     2,     2,     2,     2,     2,     2, 
 387        2,     2,     2,     2,     2,     2,     2,     2,     2,     2, 
 388        2,     2,     2,     2,     2,     2,     2,     2,     2,     2, 
 389        2,     2,     2,     2,     2,     2,     2,     2,     2,     2, 
 390        2,     2,     2,     2,     2,     2,     2,     2,     2,     2, 
 391        2,     2,     2,     2,     2,     2,     2,     2,     2,     2, 
 392        2,     2,     2,     2,     2,     2,     2,     2,     2,     2, 
 393        2,     2,     2,     2,     2,     2,     2,     2,     2,     2, 
 394        2,     2,     2,     2,     2,     2,     2,     2,     2,     2, 
 395        2,     2,     2,     2,     2,     2,     2,     2,     2,     2, 
 396        2,     2,     2,     2,     2,     2,     2,     2,     2,     2, 
 397        2,     2,     2,     2,     2,     2,     2,     2,     2,     2, 
 398        2,     2,     2,     2,     2,     2,     2,     2,     2,     2, 
 399        2,     2,     2,     2,     2,     2,     2,     2,     2,     2, 
 400        2,     2,     2,     2,     2,     2,     2,     2,     2,     2, 
 401        2,     2,     2,     2,     2,     2,     2,     2,     2,     2, 
 402        2,     2,     2,     2,     2,     2,     2,     2,     2,     2, 
 403        2,     2,     2,     2,     2,     2,     2,     2,     2,     2, 
 404        2,     2,     2,     2,     2,     2,     2,     2,     2,     2, 
 405        2,     2,     2,     2,     2,     2,     2,     2,     2,     2, 
 406        2,     2,     2,     2,     2,     2,     2,     2,     2,     2, 
 407        2,     2,     2,     2,     2,     2,     1,     2,     3,     4, 
 408        5,     6,     7,     8,     9,    10,    11,    12,    13,    14, 
 409       15,    16,    17,    18,    19,    20,    21,    22,    23,    24, 
 410       25,    26,    27,    28,    29,    30,    31,    32,    33,    34, 
 411       35,    36,    37,    38,    39,    40,    41,    42,    43,    44, 
 416 /* YYPRHS[YYN] -- Index of the first RHS symbol of rule number YYN in 
 418 static const unsigned char yyprhs
[] = 
 420        0,     0,     3,     8,     9,    13,    15,    17,    19,    23, 
 421       25,    27,    30,    34,    36,    41,    43,    47,    49,    53, 
 422       58,    60,    63,    65,    67,    69,    71,    73,    76,    79, 
 423       80,    85,    86,    91,    92,    96,    97,   101,   105,   109, 
 424      111,   113,   115,   116,   118,   120,   123,   125,   127,   130, 
 425      133,   137,   139,   142,   144,   147,   149,   152,   155,   156, 
 426      162,   164,   168,   169,   172,   175,   179,   183,   187,   189, 
 427      191,   193,   195,   197,   199,   200,   203,   204 
 430 /* YYRHS -- A `-1'-separated list of the rules' RHS. */ 
 431 static const yysigned_char yyrhs
[] = 
 433       49,     0,    -1,    50,    44,    64,    74,    -1,    -1,    50, 
 434       51,    75,    -1,    52,    -1,    45,    -1,    18,    -1,    19, 
 435       73,    73,    -1,    20,    -1,    21,    -1,    22,     5,    -1, 
 436       23,    38,    73,    -1,    24,    -1,    25,    73,    41,    73, 
 437       -1,    26,    -1,    27,    38,    73,    -1,    28,    -1,    29, 
 438       38,    73,    -1,    30,    73,    41,    73,    -1,    31,    -1, 
 439       32,    73,    -1,    34,    -1,    35,    -1,    36,    -1,    58, 
 440       -1,    55,    -1,    33,    70,    -1,    11,    47,    -1,    -1, 
 441        9,    53,    47,    61,    -1,    -1,    10,    54,    47,    61, 
 442       -1,    -1,     7,    56,    63,    -1,    -1,     6,    57,    63, 
 443       -1,     8,    37,    61,    -1,    59,    60,    61,    -1,    12, 
 444       -1,    13,    -1,    14,    -1,    -1,    37,    -1,    70,    -1, 
 445       61,    70,    -1,    37,    -1,    43,    -1,    43,     5,    -1, 
 446       43,    72,    -1,    43,     5,    72,    -1,    62,    -1,    63, 
 447       62,    -1,    65,    -1,    64,    65,    -1,    66,    -1,    52, 
 448       39,    -1,     1,    39,    -1,    -1,    43,    40,    67,    68, 
 449       39,    -1,    69,    -1,    68,    42,    69,    -1,    -1,    69, 
 450       70,    -1,    69,    71,    -1,    69,    15,    70,    -1,    69, 
 451       16,     5,    -1,    69,    17,    37,    -1,    43,    -1,    72, 
 452       -1,     4,    -1,    47,    -1,     3,    -1,     3,    -1,    -1, 
 453       44,    46,    -1,    -1,    39,    -1 
 456 /* YYRLINE[YYN] -- source line where rule number YYN was defined.  */ 
 457 static const unsigned short yyrline
[] = 
 459        0,   168,   168,   181,   183,   186,   188,   189,   190,   191, 
 460      192,   193,   194,   195,   196,   198,   199,   200,   201,   202, 
 461      204,   205,   206,   207,   208,   211,   213,   214,   218,   225, 
 462      224,   235,   234,   247,   246,   252,   252,   257,   266,   281, 
 463      283,   284,   287,   289,   294,   296,   300,   305,   310,   316, 
 464      322,   332,   335,   344,   346,   352,   354,   359,   366,   365, 
 465      370,   372,   375,   378,   380,   382,   384,   386,   390,   392, 
 466      393,   396,   402,   411,   419,   424,   430,   432 
 470 #if YYDEBUG || YYERROR_VERBOSE 
 471 /* YYTNME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM. 
 472    First, the terminals, then, starting at YYNTOKENS, nonterminals. */ 
 473 static const char *const yytname
[] = 
 475   "\"end of file\"", "error", "$undefined", "\"string\"", "\"character\"",  
 476   "\"integer\"", "\"%token\"", "\"%nterm\"", "\"%type\"",  
 477   "\"%destructor\"", "\"%printer\"", "\"%union\"", "\"%left\"",  
 478   "\"%right\"", "\"%nonassoc\"", "\"%prec\"", "\"%dprec\"", "\"%merge\"",  
 479   "\"%debug\"", "\"%define\"", "\"%defines\"", "\"%error-verbose\"",  
 480   "\"%expect\"", "\"%file-prefix\"", "\"%glr-parser\"", "\"%lex-param\"",  
 481   "\"%locations\"", "\"%name-prefix\"", "\"%no-lines\"", "\"%output\"",  
 482   "\"%parse-param\"", "\"%pure-parser\"", "\"%skeleton\"", "\"%start\"",  
 483   "\"%token-table\"", "\"%verbose\"", "\"%yacc\"", "\"type\"", "\"=\"",  
 484   "\";\"", "\":\"", "\",\"", "\"|\"", "\"identifier\"", "\"%%\"",  
 485   "\"%{...%}\"", "\"epilogue\"", "\"{...}\"", "$accept", "input",  
 486   "declarations", "declaration", "grammar_declaration", "@1", "@2",  
 487   "symbol_declaration", "@3", "@4", "precedence_declaration",  
 488   "precedence_declarator", "type.opt", "symbols.1", "symbol_def",  
 489   "symbol_defs.1", "grammar", "rules_or_grammar_declaration", "rules",  
 490   "@5", "rhses.1", "rhs", "symbol", "action", "string_as_id",  
 491   "string_content", "epilogue.opt", "semi_colon.opt", 0 
 496 /* YYTOKNUM[YYLEX-NUM] -- Internal token number corresponding to 
 498 static const unsigned short yytoknum
[] = 
 500        0,   256,   257,   258,   259,   260,   261,   262,   263,   264, 
 501      265,   266,   267,   268,   269,   270,   271,   272,   273,   274, 
 502      275,   276,   277,   278,   279,   280,   281,   282,   283,   284, 
 503      285,   286,   287,   288,   289,   290,   291,   292,   293,   294, 
 504      295,   296,   297,   298,   299,   300,   301,   302 
 508 /* YYR1[YYN] -- Symbol number of symbol that rule YYN derives.  */ 
 509 static const unsigned char yyr1
[] = 
 511        0,    48,    49,    50,    50,    51,    51,    51,    51,    51, 
 512       51,    51,    51,    51,    51,    51,    51,    51,    51,    51, 
 513       51,    51,    51,    51,    51,    52,    52,    52,    52,    53, 
 514       52,    54,    52,    56,    55,    57,    55,    55,    58,    59, 
 515       59,    59,    60,    60,    61,    61,    62,    62,    62,    62, 
 516       62,    63,    63,    64,    64,    65,    65,    65,    67,    66, 
 517       68,    68,    69,    69,    69,    69,    69,    69,    70,    70, 
 518       70,    71,    72,    73,    74,    74,    75,    75 
 521 /* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN.  */ 
 522 static const unsigned char yyr2
[] = 
 524        0,     2,     4,     0,     3,     1,     1,     1,     3,     1, 
 525        1,     2,     3,     1,     4,     1,     3,     1,     3,     4, 
 526        1,     2,     1,     1,     1,     1,     1,     2,     2,     0, 
 527        4,     0,     4,     0,     3,     0,     3,     3,     3,     1, 
 528        1,     1,     0,     1,     1,     2,     1,     1,     2,     2, 
 529        3,     1,     2,     1,     2,     1,     2,     2,     0,     5, 
 530        1,     3,     0,     2,     2,     3,     3,     3,     1,     1, 
 531        1,     1,     1,     1,     0,     2,     0,     1 
 534 /* YYDEFACT[STATE-NAME] -- Default rule to reduce with in state 
 535    STATE-NUM when YYTABLE doesn't specify something else to do.  Zero 
 536    means the default is an error.  */ 
 537 static const unsigned char yydefact
[] = 
 539        3,     0,     0,     1,    35,    33,     0,    29,    31,     0, 
 540       39,    40,    41,     7,     0,     9,    10,     0,     0,    13, 
 541        0,    15,     0,    17,     0,     0,    20,     0,     0,    22, 
 542       23,    24,     0,     6,    76,     5,    26,    25,    42,     0, 
 543        0,     0,     0,     0,    28,    73,     0,    11,     0,     0, 
 544        0,     0,     0,    21,    72,    70,    68,    27,    69,     0, 
 545        0,     0,     0,    53,    55,    77,     4,    43,     0,    46, 
 546       47,    51,    36,    34,    37,    44,     0,     0,     8,    12, 
 547        0,    16,    18,     0,    57,    58,    56,     0,    54,     2, 
 548       38,    48,    49,    52,    45,    30,    32,    14,    19,    62, 
 549       75,    50,     0,    60,    59,    62,     0,     0,     0,    71, 
 550       63,    64,    61,    65,    66,    67 
 553 /* YYDEFGOTO[NTERM-NUM]. */ 
 554 static const yysigned_char yydefgoto
[] = 
 556       -1,     1,     2,    34,    61,    42,    43,    36,    40,    39, 
 557       37,    38,    68,    74,    71,    72,    62,    63,    64,    99, 
 558      102,   103,    75,   111,    58,    46,    89,    66 
 561 /* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing 
 563 #define YYPACT_NINF -64 
 564 static const yysigned_char yypact
[] = 
 566      -64,     9,   107,   -64,   -64,   -64,   -13,   -64,   -64,    -9, 
 567      -64,   -64,   -64,   -64,    27,   -64,   -64,    38,     3,   -64, 
 568       27,   -64,     6,   -64,     7,    27,   -64,    27,    -1,   -64, 
 569      -64,   -64,    79,   -64,    10,   -64,   -64,   -64,    13,   -17, 
 570      -17,    -1,     8,    11,   -64,   -64,    27,   -64,    27,    15, 
 571       27,    27,    16,   -64,   -64,   -64,   -64,   -64,   -64,    20, 
 572       14,    21,     4,   -64,   -64,   -64,   -64,   -64,    -1,   -64, 
 573       18,   -64,   -17,   -17,    -1,   -64,    -1,    -1,   -64,   -64, 
 574       27,   -64,   -64,    27,   -64,   -64,   -64,    17,   -64,   -64, 
 575       -1,    62,   -64,   -64,   -64,    -1,    -1,   -64,   -64,   -64, 
 576      -64,   -64,   -20,    36,   -64,   -64,    -1,    61,    32,   -64, 
 577      -64,   -64,    36,   -64,   -64,   -64 
 580 /* YYPGOTO[NTERM-NUM].  */ 
 581 static const yysigned_char yypgoto
[] = 
 583      -64,   -64,   -64,   -64,    68,   -64,   -64,   -64,   -64,   -64, 
 584      -64,   -64,   -64,   -43,   -37,    31,   -64,    12,   -64,   -64, 
 585      -64,   -33,   -28,   -64,   -63,   -19,   -64,   -64 
 588 /* YYTABLE[YYPACT[STATE-NUM]].  What to do in state STATE-NUM.  If 
 589    positive, shift that token.  If negative, reduce the rule which 
 590    number is the opposite.  If zero, do what YYDEFACT says. 
 591    If YYTABLE_NINF, parse error.  */ 
 592 #define YYTABLE_NINF -75 
 593 static const yysigned_char yytable
[] = 
 595       57,    49,    54,    55,   -74,    59,    52,    92,    53,     3, 
 596        4,     5,     6,     7,     8,     9,    10,    11,    12,   104, 
 597       69,    54,   105,    91,    41,    90,    70,    78,   101,    79, 
 598       45,    81,    82,    95,    96,    93,    93,    28,    44,    54, 
 599       55,    48,    56,    47,    50,    51,    94,    60,    87,    65, 
 600       67,   106,   107,   108,    85,    76,    80,    83,    77,    84, 
 601       86,    97,    94,   100,    98,    54,   114,    94,    94,   115, 
 602       35,    73,   112,     0,    88,   110,     0,     0,   113,    56, 
 603       59,     0,     0,   109,   110,     4,     5,     6,     7,     8, 
 604        9,    10,    11,    12,     0,     0,     0,     0,     0,     0, 
 605        0,     0,     0,     0,     0,     0,     0,     0,     0,     0, 
 606        0,     0,    28,     4,     5,     6,     7,     8,     9,    10, 
 607       11,    12,    60,     0,     0,    13,    14,    15,    16,    17, 
 608       18,    19,    20,    21,    22,    23,    24,    25,    26,    27, 
 609       28,    29,    30,    31,     0,     0,     0,     0,     0,     0, 
 613 static const yysigned_char yycheck
[] = 
 615       28,    20,     3,     4,     0,     1,    25,    70,    27,     0, 
 616        6,     7,     8,     9,    10,    11,    12,    13,    14,    39, 
 617       37,     3,    42,     5,    37,    68,    43,    46,    91,    48, 
 618        3,    50,    51,    76,    77,    72,    73,    33,    47,     3, 
 619        4,    38,    43,     5,    38,    38,    74,    43,    44,    39, 
 620       37,    15,    16,    17,    40,    47,    41,    41,    47,    39, 
 621       39,    80,    90,    46,    83,     3,     5,    95,    96,    37, 
 622        2,    40,   105,    -1,    62,   103,    -1,    -1,   106,    43, 
 623        1,    -1,    -1,    47,   112,     6,     7,     8,     9,    10, 
 624       11,    12,    13,    14,    -1,    -1,    -1,    -1,    -1,    -1, 
 625       -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1, 
 626       -1,    -1,    33,     6,     7,     8,     9,    10,    11,    12, 
 627       13,    14,    43,    -1,    -1,    18,    19,    20,    21,    22, 
 628       23,    24,    25,    26,    27,    28,    29,    30,    31,    32, 
 629       33,    34,    35,    36,    -1,    -1,    -1,    -1,    -1,    -1, 
 633 /* YYSTOS[STATE-NUM] -- The (internal number of the) accessing 
 634    symbol of state STATE-NUM.  */ 
 635 static const unsigned char yystos
[] = 
 637        0,    49,    50,     0,     6,     7,     8,     9,    10,    11, 
 638       12,    13,    14,    18,    19,    20,    21,    22,    23,    24, 
 639       25,    26,    27,    28,    29,    30,    31,    32,    33,    34, 
 640       35,    36,    44,    45,    51,    52,    55,    58,    59,    57, 
 641       56,    37,    53,    54,    47,     3,    73,     5,    38,    73, 
 642       38,    38,    73,    73,     3,     4,    43,    70,    72,     1, 
 643       43,    52,    64,    65,    66,    39,    75,    37,    60,    37, 
 644       43,    62,    63,    63,    61,    70,    47,    47,    73,    73, 
 645       41,    73,    73,    41,    39,    40,    39,    44,    65,    74, 
 646       61,     5,    72,    62,    70,    61,    61,    73,    73,    67, 
 647       46,    72,    68,    69,    39,    42,    15,    16,    17,    47, 
 648       70,    71,    69,    70,     5,    37 
 651 #if ! defined (YYSIZE_T) && defined (__SIZE_TYPE__) 
 652 # define YYSIZE_T __SIZE_TYPE__ 
 654 #if ! defined (YYSIZE_T) && defined (size_t) 
 655 # define YYSIZE_T size_t 
 657 #if ! defined (YYSIZE_T) 
 658 # if defined (__STDC__) || defined (__cplusplus) 
 659 #  include <stddef.h> /* INFRINGES ON USER NAME SPACE */ 
 660 #  define YYSIZE_T size_t 
 663 #if ! defined (YYSIZE_T) 
 664 # define YYSIZE_T unsigned int 
 667 #define yyerrok         (yyerrstatus = 0) 
 668 #define yyclearin       (yychar = YYEMPTY) 
 672 #define YYACCEPT        goto yyacceptlab 
 673 #define YYABORT         goto yyabortlab 
 674 #define YYERROR         goto yyerrlab1 
 676 /* Like YYERROR except do call yyerror.  This remains here temporarily 
 677    to ease the transition to the new meaning of YYERROR, for GCC. 
 678    Once GCC version 2 has supplanted version 1, this can go.  */ 
 680 #define YYFAIL          goto yyerrlab 
 682 #define YYRECOVERING()  (!!yyerrstatus) 
 684 #define YYBACKUP(Token, Value)                                  \ 
 686   if (yychar == YYEMPTY && yylen == 1)                          \ 
 690       yychar1 = YYTRANSLATE (yychar);                           \ 
 696       yyerror ("syntax error: cannot back up");                 \ 
 702 #define YYERRCODE       256 
 704 /* YYLLOC_DEFAULT -- Compute the default location (before the actions 
 707 #ifndef YYLLOC_DEFAULT 
 708 # define YYLLOC_DEFAULT(Current, Rhs, N)           \ 
 709   Current.first_line   = Rhs[1].first_line;      \ 
 710   Current.first_column = Rhs[1].first_column;    \ 
 711   Current.last_line    = Rhs[N].last_line;       \ 
 712   Current.last_column  = Rhs[N].last_column; 
 715 /* YYLEX -- calling `yylex' with the right arguments.  */ 
 718 # define YYLEX yylex (&yylval, &yylloc, YYLEX_PARAM) 
 720 # define YYLEX yylex (&yylval, &yylloc) 
 723 /* Enable debugging if requested.  */ 
 727 #  include <stdio.h> /* INFRINGES ON USER NAME SPACE */ 
 728 #  define YYFPRINTF fprintf 
 731 # define YYDPRINTF(Args)                        \ 
 736 # define YYDSYMPRINT(Args)                      \ 
 741 /* Nonzero means print parse trace.  It is left uninitialized so that 
 742    multiple parsers can coexist.  */ 
 745 # define YYDPRINTF(Args) 
 746 # define YYDSYMPRINT(Args) 
 747 #endif /* !YYDEBUG */ 
 749 /* YYINITDEPTH -- initial size of the parser's stacks.  */ 
 751 # define YYINITDEPTH 200 
 754 /* YYMAXDEPTH -- maximum size the stacks can grow to (effective only 
 755    if the built-in stack extension method is used). 
 757    Do not make this value too large; the results are undefined if 
 758    SIZE_MAX < YYSTACK_BYTES (YYMAXDEPTH) 
 759    evaluated with infinite-precision integer arithmetic.  */ 
 766 # define YYMAXDEPTH 10000 
 774 #  if defined (__GLIBC__) && defined (_STRING_H) 
 775 #   define yystrlen strlen 
 777 /* Return the length of YYSTR.  */ 
 779 #   if defined (__STDC__) || defined (__cplusplus) 
 780 yystrlen (const char *yystr
) 
 786   register const char *yys 
= yystr
; 
 788   while (*yys
++ != '\0') 
 791   return yys 
- yystr 
- 1; 
 797 #  if defined (__GLIBC__) && defined (_STRING_H) && defined (_GNU_SOURCE) 
 798 #   define yystpcpy stpcpy 
 800 /* Copy YYSRC to YYDEST, returning the address of the terminating '\0' in 
 803 #   if defined (__STDC__) || defined (__cplusplus) 
 804 yystpcpy (char *yydest
, const char *yysrc
) 
 806 yystpcpy (yydest
, yysrc
) 
 811   register char *yyd 
= yydest
; 
 812   register const char *yys 
= yysrc
; 
 814   while ((*yyd
++ = *yys
++) != '\0') 
 822 #endif /* !YYERROR_VERBOSE */ 
 827 /*-----------------------------. 
 828 | Print this symbol on YYOUT.  | 
 829 `-----------------------------*/ 
 831 #if defined (__STDC__) || defined (__cplusplus) 
 833 yysymprint (FILE *yyout
, int yytype
, YYSTYPE yyvalue
, YYLTYPE yylocation
) 
 836 yysymprint (yyout
, yytype
, yyvalue
, yylocation
) 
 843   /* Pacify ``unused variable'' warnings.  */ 
 847   if (yytype 
< YYNTOKENS
) 
 849       YYFPRINTF (yyout
, "token %s (", yytname
[yytype
]); 
 851       YYPRINT (yyout
, yytoknum
[yytype
], yyvalue
); 
 855     YYFPRINTF (yyout
, "nterm %s (", yytname
[yytype
]); 
 862   YYFPRINTF (yyout
, ")"); 
 864 #endif /* YYDEBUG. */ 
 867 /*-----------------------------------------------. 
 868 | Release the memory associated to this symbol.  | 
 869 `-----------------------------------------------*/ 
 871 #if defined (__STDC__) || defined (__cplusplus) 
 873 yydestruct (int yytype
, YYSTYPE yyvalue
, YYLTYPE yylocation
) 
 876 yydestruct (yytype
, yyvalue
, yylocation
) 
 882   /* Pacify ``unused variable'' warnings.  */ 
 895 /* Prevent warnings from -Wmissing-prototypes.  */ 
 898 # if defined (__STDC__) || defined (__cplusplus) 
 899 int yyparse (void *YYPARSE_PARAM
); 
 903 #else /* ! YYPARSE_PARAM */ 
 904 #if defined (__STDC__) || defined (__cplusplus) 
 921 # if defined (__STDC__) || defined (__cplusplus) 
 922 int yyparse (void *YYPARSE_PARAM
) 
 924 int yyparse (YYPARSE_PARAM
) 
 927 #else /* ! YYPARSE_PARAM */ 
 928 #if defined (__STDC__) || defined (__cplusplus) 
 938   /* The lookahead symbol.  */ 
 941 /* The semantic value of the lookahead symbol.  */ 
 944 /* Number of parse errors so far.  */ 
 946 /* Location data for the lookahead symbol.  */ 
 949   register int yystate
; 
 952   /* Number of tokens to shift before error messages enabled.  */ 
 954   /* Lookahead token as an internal (translated) token number.  */ 
 957   /* Three stacks and their tools: 
 958      `yyss': related to states, 
 959      `yyvs': related to semantic values, 
 960      `yyls': related to locations. 
 962      Refer to the stacks thru separate pointers, to allow yyoverflow 
 963      to reallocate them elsewhere.  */ 
 965   /* The state stack.  */ 
 966   short yyssa
[YYINITDEPTH
]; 
 968   register short *yyssp
; 
 970   /* The semantic value stack.  */ 
 971   YYSTYPE yyvsa
[YYINITDEPTH
]; 
 972   YYSTYPE 
*yyvs 
= yyvsa
; 
 973   register YYSTYPE 
*yyvsp
; 
 975   /* The location stack.  */ 
 976   YYLTYPE yylsa
[YYINITDEPTH
]; 
 977   YYLTYPE 
*yyls 
= yylsa
; 
 980 #define YYPOPSTACK   (yyvsp--, yyssp--, yylsp--) 
 982   YYSIZE_T yystacksize 
= YYINITDEPTH
; 
 984   /* The variables used to return semantic value and location from the 
 989   /* When reducing, the number of symbols on the RHS of the reduced 
 993   YYDPRINTF ((stderr
, "Starting parse\n")); 
 998   yychar 
= YYEMPTY
;             /* Cause a token to be read.  */ 
1000   /* Initialize stack pointers. 
1001      Waste one element of value and location stack 
1002      so that they stay on the same level as the state stack. 
1003      The wasted elements are never initialized.  */ 
1010 /*------------------------------------------------------------. 
1011 | yynewstate -- Push a new state, which is found in yystate.  | 
1012 `------------------------------------------------------------*/ 
1014   /* In all cases, when you get here, the value and location stacks 
1015      have just been pushed. so pushing a state here evens the stacks. 
1022   if (yyss 
+ yystacksize 
- 1 <= yyssp
) 
1024       /* Get the current used size of the three stacks, in elements.  */ 
1025       YYSIZE_T yysize 
= yyssp 
- yyss 
+ 1; 
1029         /* Give user a chance to reallocate the stack. Use copies of 
1030            these so that the &'s don't force the real ones into 
1032         YYSTYPE 
*yyvs1 
= yyvs
; 
1033         short *yyss1 
= yyss
; 
1034         YYLTYPE 
*yyls1 
= yyls
; 
1036         /* Each stack pointer address is followed by the size of the 
1037            data in use in that stack, in bytes.  This used to be a 
1038            conditional around just the two extra args, but that might 
1039            be undefined if yyoverflow is a macro.  */ 
1040         yyoverflow ("parser stack overflow", 
1041                     &yyss1
, yysize 
* sizeof (*yyssp
), 
1042                     &yyvs1
, yysize 
* sizeof (*yyvsp
), 
1043                     &yyls1
, yysize 
* sizeof (*yylsp
), 
1049 #else /* no yyoverflow */ 
1050 # ifndef YYSTACK_RELOCATE 
1053       /* Extend the stack our own way.  */ 
1054       if (YYMAXDEPTH 
<= yystacksize
) 
1057       if (YYMAXDEPTH 
< yystacksize
) 
1058         yystacksize 
= YYMAXDEPTH
; 
1061         short *yyss1 
= yyss
; 
1062         union yyalloc 
*yyptr 
= 
1063           (union yyalloc 
*) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize
)); 
1066         YYSTACK_RELOCATE (yyss
); 
1067         YYSTACK_RELOCATE (yyvs
); 
1068         YYSTACK_RELOCATE (yyls
); 
1069 #  undef YYSTACK_RELOCATE 
1071           YYSTACK_FREE (yyss1
); 
1074 #endif /* no yyoverflow */ 
1076       yyssp 
= yyss 
+ yysize 
- 1; 
1077       yyvsp 
= yyvs 
+ yysize 
- 1; 
1078       yylsp 
= yyls 
+ yysize 
- 1; 
1080       YYDPRINTF ((stderr
, "Stack size increased to %lu\n", 
1081                   (unsigned long int) yystacksize
)); 
1083       if (yyss 
+ yystacksize 
- 1 <= yyssp
) 
1087   YYDPRINTF ((stderr
, "Entering state %d\n", yystate
)); 
1096 /* Do appropriate processing given the current state.  */ 
1097 /* Read a lookahead token if we need one and don't already have one.  */ 
1100   /* First try to decide what to do without reference to lookahead token.  */ 
1102   yyn 
= yypact
[yystate
]; 
1103   if (yyn 
== YYPACT_NINF
) 
1106   /* Not known => get a lookahead token if don't already have one.  */ 
1108   /* yychar is either YYEMPTY or YYEOF 
1109      or a valid token in external form.  */ 
1111   if (yychar 
== YYEMPTY
) 
1113       YYDPRINTF ((stderr
, "Reading a token: ")); 
1117   /* Convert token to internal form (in yychar1) for indexing tables with.  */ 
1119   if (yychar 
<= 0)              /* This means end of input.  */ 
1122       yychar 
= YYEOF
;           /* Don't call YYLEX any more.  */ 
1124       YYDPRINTF ((stderr
, "Now at end of input.\n")); 
1128       yychar1 
= YYTRANSLATE (yychar
); 
1130       /* We have to keep this `#if YYDEBUG', since we use variables 
1131          which are defined only if `YYDEBUG' is set.  */ 
1132       YYDPRINTF ((stderr
, "Next token is ")); 
1133       YYDSYMPRINT ((stderr
, yychar1
, yylval
, yyloc
)); 
1134       YYDPRINTF ((stderr
, "\n")); 
1137   /* If the proper action on seeing token YYCHAR1 is to reduce or to 
1138      detect an error, take that action.  */ 
1140   if (yyn 
< 0 || YYLAST 
< yyn 
|| yycheck
[yyn
] != yychar1
) 
1145       if (yyn 
== 0 || yyn 
== YYTABLE_NINF
) 
1154   /* Shift the lookahead token.  */ 
1155   YYDPRINTF ((stderr
, "Shifting token %d (%s), ", 
1156               yychar
, yytname
[yychar1
])); 
1158   /* Discard the token being shifted unless it is eof.  */ 
1159   if (yychar 
!= YYEOF
) 
1165   /* Count tokens shifted since error; after three, turn off error 
1174 /*-----------------------------------------------------------. 
1175 | yydefault -- do the default action for the current state.  | 
1176 `-----------------------------------------------------------*/ 
1178   yyn 
= yydefact
[yystate
]; 
1184 /*-----------------------------. 
1185 | yyreduce -- Do a reduction.  | 
1186 `-----------------------------*/ 
1188   /* yyn is the number of a rule to reduce with.  */ 
1191   /* If YYLEN is nonzero, implement the default value of the action: 
1194      Otherwise, the following line sets YYVAL to garbage. 
1195      This behavior is undocumented and Bison 
1196      users should not rely upon it.  Assigning to YYVAL 
1197      unconditionally makes the parser a bit smaller, and it avoids a 
1198      GCC warning that YYVAL may be used uninitialized.  */ 
1199   yyval 
= yyvsp
[1-yylen
]; 
1201   /* Default location. */ 
1202   YYLLOC_DEFAULT (yyloc
, (yylsp 
- yylen
), yylen
); 
1205   /* We have to keep this `#if YYDEBUG', since we use variables which 
1206      are defined only if `YYDEBUG' is set.  */ 
1211       YYFPRINTF (stderr
, "Reducing via rule %d (line %d), ", 
1212                  yyn 
- 1, yyrline
[yyn
]); 
1214       /* Print the symbols being reduced, and their result.  */ 
1215       for (yyi 
= yyprhs
[yyn
]; 0 <= yyrhs
[yyi
]; yyi
++) 
1216         YYFPRINTF (stderr
, "%s ", yytname
[yyrhs
[yyi
]]); 
1217       YYFPRINTF (stderr
, " -> %s\n", yytname
[yyr1
[yyn
]]); 
1223 #line 170 "parse-gram.y" 
1225       yycontrol
->errcode 
= 0; 
1226       epilogue_set (yyvsp
[0].string
, yylsp
[0]); 
1231 #line 188 "parse-gram.y" 
1232     { prologue_augment (yyvsp
[0].string
, yylsp
[0]); } 
1236 #line 189 "parse-gram.y" 
1241 #line 190 "parse-gram.y" 
1242     { muscle_insert (yyvsp
[-1].string
, yyvsp
[0].string
); } 
1246 #line 191 "parse-gram.y" 
1247     { defines_flag 
= 1; } 
1251 #line 192 "parse-gram.y" 
1252     { error_verbose 
= 1; } 
1256 #line 193 "parse-gram.y" 
1257     { expected_conflicts 
= yyvsp
[0].integer
; } 
1261 #line 194 "parse-gram.y" 
1262     { spec_file_prefix 
= yyvsp
[0].string
; } 
1266 #line 195 "parse-gram.y" 
1271 #line 197 "parse-gram.y" 
1272     { muscle_pair_list_grow ("lex_param", yyvsp
[-2].string
, yyvsp
[0].string
); } 
1276 #line 198 "parse-gram.y" 
1277     { locations_flag 
= 1; } 
1281 #line 199 "parse-gram.y" 
1282     { spec_name_prefix 
= yyvsp
[0].string
; } 
1286 #line 200 "parse-gram.y" 
1287     { no_lines_flag 
= 1; } 
1291 #line 201 "parse-gram.y" 
1292     { spec_outfile 
= yyvsp
[0].string
; } 
1296 #line 203 "parse-gram.y" 
1297     { muscle_pair_list_grow ("parse_param", yyvsp
[-2].string
, yyvsp
[0].string
); } 
1301 #line 204 "parse-gram.y" 
1302     { pure_parser 
= 1; } 
1306 #line 205 "parse-gram.y" 
1307     { skeleton 
= yyvsp
[0].string
; } 
1311 #line 206 "parse-gram.y" 
1312     { token_table_flag 
= 1; } 
1316 #line 207 "parse-gram.y" 
1317     { report_flag 
= 1; } 
1321 #line 208 "parse-gram.y" 
1326 #line 215 "parse-gram.y" 
1328       grammar_start_symbol_set (yyvsp
[0].symbol
, yylsp
[0]); 
1333 #line 219 "parse-gram.y" 
1336       MUSCLE_INSERT_INT ("stype_line", yylsp
[0].first_line
); 
1337       muscle_insert ("stype", yyvsp
[0].string
); 
1342 #line 225 "parse-gram.y" 
1343     { current_braced_code 
= destructor_braced_code
; } 
1347 #line 227 "parse-gram.y" 
1349       symbol_list_t 
*list
; 
1350       for (list 
= yyvsp
[0].list
; list
; list 
= list
->next
) 
1351         symbol_destructor_set (list
->sym
, yyvsp
[-1].string
, yylsp
[-1]); 
1352       symbol_list_free (yyvsp
[0].list
); 
1353       current_braced_code 
= action_braced_code
; 
1358 #line 235 "parse-gram.y" 
1359     { current_braced_code 
= printer_braced_code
; } 
1363 #line 237 "parse-gram.y" 
1365       symbol_list_t 
*list
; 
1366       for (list 
= yyvsp
[0].list
; list
; list 
= list
->next
) 
1367         symbol_printer_set (list
->sym
, yyvsp
[-1].string
, list
->location
); 
1368       symbol_list_free (yyvsp
[0].list
); 
1369       current_braced_code 
= action_braced_code
; 
1374 #line 247 "parse-gram.y" 
1375     { current_class 
= nterm_sym
; } 
1379 #line 248 "parse-gram.y" 
1381       current_class 
= unknown_sym
; 
1382       current_type 
= NULL
; 
1387 #line 252 "parse-gram.y" 
1388     { current_class 
= token_sym
; } 
1392 #line 253 "parse-gram.y" 
1394       current_class 
= unknown_sym
; 
1395       current_type 
= NULL
; 
1400 #line 258 "parse-gram.y" 
1402       symbol_list_t 
*list
; 
1403       for (list 
= yyvsp
[0].list
; list
; list 
= list
->next
) 
1404         symbol_type_set (list
->sym
, yyvsp
[-1].string
, yylsp
[-1]); 
1405       symbol_list_free (yyvsp
[0].list
); 
1410 #line 268 "parse-gram.y" 
1412       symbol_list_t 
*list
; 
1414       for (list 
= yyvsp
[0].list
; list
; list 
= list
->next
) 
1416           symbol_type_set (list
->sym
, current_type
, yylsp
[-1]); 
1417           symbol_precedence_set (list
->sym
, current_prec
, yyvsp
[-2].assoc
, yylsp
[-2]); 
1419       symbol_list_free (yyvsp
[0].list
); 
1420       current_type 
= NULL
; 
1425 #line 282 "parse-gram.y" 
1426     { yyval
.assoc 
= left_assoc
; } 
1430 #line 283 "parse-gram.y" 
1431     { yyval
.assoc 
= right_assoc
; } 
1435 #line 284 "parse-gram.y" 
1436     { yyval
.assoc 
= non_assoc
; } 
1440 #line 288 "parse-gram.y" 
1441     { current_type 
= NULL
;} 
1445 #line 289 "parse-gram.y" 
1446     { current_type 
= yyvsp
[0].string
; } 
1450 #line 295 "parse-gram.y" 
1451     { yyval
.list 
= symbol_list_new (yyvsp
[0].symbol
, yylsp
[0]); } 
1455 #line 296 "parse-gram.y" 
1456     { yyval
.list 
= symbol_list_prepend (yyvsp
[-1].list
, yyvsp
[0].symbol
, yylsp
[0]); } 
1460 #line 302 "parse-gram.y" 
1462        current_type 
= yyvsp
[0].string
; 
1467 #line 306 "parse-gram.y" 
1469        symbol_class_set (yyvsp
[0].symbol
, current_class
, yylsp
[0]); 
1470        symbol_type_set (yyvsp
[0].symbol
, current_type
, yylsp
[0]); 
1475 #line 311 "parse-gram.y" 
1477       symbol_class_set (yyvsp
[-1].symbol
, current_class
, yylsp
[-1]); 
1478       symbol_type_set (yyvsp
[-1].symbol
, current_type
, yylsp
[-1]); 
1479       symbol_user_token_number_set (yyvsp
[-1].symbol
, yyvsp
[0].integer
, yylsp
[0]); 
1484 #line 317 "parse-gram.y" 
1486       symbol_class_set (yyvsp
[-1].symbol
, current_class
, yylsp
[-1]); 
1487       symbol_type_set (yyvsp
[-1].symbol
, current_type
, yylsp
[-1]); 
1488       symbol_make_alias (yyvsp
[-1].symbol
, yyvsp
[0].symbol
, yyloc
); 
1493 #line 323 "parse-gram.y" 
1495       symbol_class_set (yyvsp
[-2].symbol
, current_class
, yylsp
[-2]); 
1496       symbol_type_set (yyvsp
[-2].symbol
, current_type
, yylsp
[-2]); 
1497       symbol_user_token_number_set (yyvsp
[-2].symbol
, yyvsp
[-1].integer
, yylsp
[-1]); 
1498       symbol_make_alias (yyvsp
[-2].symbol
, yyvsp
[0].symbol
, yyloc
); 
1503 #line 334 "parse-gram.y" 
1508 #line 336 "parse-gram.y" 
1513 #line 355 "parse-gram.y" 
1516         complain_at (yyloc
, _("POSIX forbids declarations in the grammar")); 
1521 #line 360 "parse-gram.y" 
1528 #line 366 "parse-gram.y" 
1529     { current_lhs 
= yyvsp
[-1].symbol
; current_lhs_location 
= yylsp
[-1]; } 
1533 #line 367 "parse-gram.y" 
1538 #line 371 "parse-gram.y" 
1539     { grammar_rule_end (yylsp
[0]); } 
1543 #line 372 "parse-gram.y" 
1544     { grammar_rule_end (yylsp
[0]); } 
1548 #line 377 "parse-gram.y" 
1549     { grammar_rule_begin (current_lhs
, current_lhs_location
); } 
1553 #line 379 "parse-gram.y" 
1554     { grammar_current_rule_symbol_append (yyvsp
[0].symbol
, yylsp
[0]); } 
1558 #line 381 "parse-gram.y" 
1559     { grammar_current_rule_action_append (yyvsp
[0].string
, yylsp
[0]); } 
1563 #line 383 "parse-gram.y" 
1564     { grammar_current_rule_prec_set (yyvsp
[0].symbol
, yylsp
[0]); } 
1568 #line 385 "parse-gram.y" 
1569     { grammar_current_rule_dprec_set (yyvsp
[0].integer
, yylsp
[0]); } 
1573 #line 387 "parse-gram.y" 
1574     { grammar_current_rule_merge_set (yyvsp
[0].string
, yylsp
[0]); } 
1578 #line 391 "parse-gram.y" 
1579     { yyval
.symbol 
= yyvsp
[0].symbol
; } 
1583 #line 392 "parse-gram.y" 
1584     { yyval
.symbol 
= yyvsp
[0].symbol
; } 
1588 #line 393 "parse-gram.y" 
1589     { yyval
.symbol 
= symbol_get (yyvsp
[0].string
, yylsp
[0]); } 
1593 #line 398 "parse-gram.y" 
1594     { yyval
.string 
= yyvsp
[0].string
; } 
1598 #line 404 "parse-gram.y" 
1600       yyval
.symbol 
= symbol_get (yyvsp
[0].string
, yylsp
[0]); 
1601       symbol_class_set (yyval
.symbol
, token_sym
, yylsp
[0]); 
1606 #line 413 "parse-gram.y" 
1608       yyval
.string 
= yyvsp
[0].string 
+ 1; 
1609       yyval
.string
[strlen (yyval
.string
) - 1] = '\0'; 
1614 #line 421 "parse-gram.y" 
1616       yyval
.string 
= xstrdup (""); 
1621 #line 425 "parse-gram.y" 
1623       yyval
.string 
= yyvsp
[0].string
; 
1630 /* Line 1022 of /tmp/prefix/share/bison/yacc.c.  */ 
1631 #line 1632 "parse-gram.c" 
1640       short *yyssp1 
= yyss 
- 1; 
1641       YYFPRINTF (stderr
, "state stack now"); 
1642       while (yyssp1 
!= yyssp
) 
1643         YYFPRINTF (stderr
, " %d", *++yyssp1
); 
1644       YYFPRINTF (stderr
, "\n"); 
1651   /* Now `shift' the result of the reduction.  Determine what state 
1652      that goes to, based on the state we popped back to and the rule 
1653      number reduced by.  */ 
1657   yystate 
= yypgoto
[yyn 
- YYNTOKENS
] + *yyssp
; 
1658   if (0 <= yystate 
&& yystate 
<= YYLAST 
&& yycheck
[yystate
] == *yyssp
) 
1659     yystate 
= yytable
[yystate
]; 
1661     yystate 
= yydefgoto
[yyn 
- YYNTOKENS
]; 
1666 /*------------------------------------. 
1667 | yyerrlab -- here on detecting error | 
1668 `------------------------------------*/ 
1670   /* If not already recovering from an error, report this error.  */ 
1675       yyn 
= yypact
[yystate
]; 
1677       if (YYPACT_NINF 
< yyn 
&& yyn 
< YYLAST
) 
1679           YYSIZE_T yysize 
= 0; 
1680           int yytype 
= YYTRANSLATE (yychar
); 
1685           /* Start YYX at -YYN if negative to avoid negative indexes in 
1687           for (yyx 
= yyn 
< 0 ? -yyn 
: 0; 
1688                yyx 
< (int) (sizeof (yytname
) / sizeof (char *)); yyx
++) 
1689             if (yycheck
[yyx 
+ yyn
] == yyx 
&& yyx 
!= YYTERROR
) 
1690               yysize 
+= yystrlen (yytname
[yyx
]) + 15, yycount
++; 
1691           yysize 
+= yystrlen ("parse error, unexpected ") + 1; 
1692           yysize 
+= yystrlen (yytname
[yytype
]); 
1693           yymsg 
= (char *) YYSTACK_ALLOC (yysize
); 
1696               char *yyp 
= yystpcpy (yymsg
, "parse error, unexpected "); 
1697               yyp 
= yystpcpy (yyp
, yytname
[yytype
]); 
1702                   for (yyx 
= yyn 
< 0 ? -yyn 
: 0; 
1703                        yyx 
< (int) (sizeof (yytname
) / sizeof (char *)); 
1705                     if (yycheck
[yyx 
+ yyn
] == yyx 
&& yyx 
!= YYTERROR
) 
1707                         const char *yyq 
= ! yycount 
? ", expecting " : " or "; 
1708                         yyp 
= yystpcpy (yyp
, yyq
); 
1709                         yyp 
= yystpcpy (yyp
, yytname
[yyx
]); 
1714               YYSTACK_FREE (yymsg
); 
1717             yyerror ("parse error; also virtual memory exhausted"); 
1720 #endif /* YYERROR_VERBOSE */ 
1721         yyerror ("parse error"); 
1726 /*----------------------------------------------------. 
1727 | yyerrlab1 -- error raised explicitly by an action.  | 
1728 `----------------------------------------------------*/ 
1730   if (yyerrstatus 
== 3) 
1732       /* If just tried and failed to reuse lookahead token after an 
1733          error, discard it.  */ 
1735       /* Return failure if at end of input.  */ 
1736       if (yychar 
== YYEOF
) 
1738           /* Pop the error token.  */ 
1740           /* Pop the rest of the stack.  */ 
1741           while (yyss 
< yyssp
) 
1743               YYDPRINTF ((stderr
, "Error: popping ")); 
1744               YYDSYMPRINT ((stderr
, 
1747               YYDPRINTF ((stderr
, "\n")); 
1748               yydestruct (yystos
[*yyssp
], *yyvsp
, *yylsp
); 
1754       YYDPRINTF ((stderr
, "Discarding token %d (%s).\n", 
1755                   yychar
, yytname
[yychar1
])); 
1756       yydestruct (yychar1
, yylval
, yylloc
); 
1760   /* Else will try to reuse lookahead token after shifting the error 
1763   yyerrstatus 
= 3;      /* Each real token shifted decrements this.  */ 
1767       yyn 
= yypact
[yystate
]; 
1768       if (yyn 
!= YYPACT_NINF
) 
1771           if (0 <= yyn 
&& yyn 
<= YYLAST 
&& yycheck
[yyn
] == YYTERROR
) 
1779       /* Pop the current state because it cannot handle the error token.  */ 
1783       YYDPRINTF ((stderr
, "Error: popping ")); 
1784       YYDSYMPRINT ((stderr
, 
1785                     yystos
[*yyssp
], *yyvsp
, *yylsp
)); 
1786       YYDPRINTF ((stderr
, "\n")); 
1788       yydestruct (yystos
[yystate
], *yyvsp
, *yylsp
); 
1796           short *yyssp1 
= yyss 
- 1; 
1797           YYFPRINTF (stderr
, "Error: state stack now"); 
1798           while (yyssp1 
!= yyssp
) 
1799             YYFPRINTF (stderr
, " %d", *++yyssp1
); 
1800           YYFPRINTF (stderr
, "\n"); 
1808   YYDPRINTF ((stderr
, "Shifting error token, ")); 
1817 /*-------------------------------------. 
1818 | yyacceptlab -- YYACCEPT comes here.  | 
1819 `-------------------------------------*/ 
1824 /*-----------------------------------. 
1825 | yyabortlab -- YYABORT comes here.  | 
1826 `-----------------------------------*/ 
1832 /*----------------------------------------------. 
1833 | yyoverflowlab -- parser overflow comes here.  | 
1834 `----------------------------------------------*/ 
1836   yyerror ("parser stack overflow"); 
1844     YYSTACK_FREE (yyss
); 
1850 #line 434 "parse-gram.y" 
1852 /*------------------------------------------------------------------. 
1853 | When debugging the parser, display tokens' locations and values.  | 
1854 `------------------------------------------------------------------*/ 
1857 yyprint (FILE *file
, 
1858          int type
, const yystype 
*value
) 
1864       fprintf (file
, " = '%s'", value
->string
); 
1868       fprintf (file
, " = %s", value
->symbol
->tag
); 
1872       fprintf (file
, " = %d", value
->integer
); 
1876       fprintf (file
, " = \"%s\"", value
->string
); 
1880       fprintf (file
, " = <%s>", value
->string
); 
1886       fprintf (file
, " = {{ %s }}", value
->string
); 
1892 gram_error (location_t 
*yylloc
, const char *msg
) 
1894   complain_at (*yylloc
, "%s", msg
);