1 /* A Bison parser, made from parse-gram.y
4 /* Skeleton output parser for Bison,
5 Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002 Free Software
8 This program is free software; you can redistribute it and/or modify
9 it under the terms of the GNU General Public License as published by
10 the Free Software Foundation; either version 2, or (at your option)
13 This program is distributed in the hope that it will be useful,
14 but WITHOUT ANY WARRANTY; without even the implied warranty of
15 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 GNU General Public License for more details.
18 You should have received a copy of the GNU General Public License
19 along with this program; if not, write to the Free Software
20 Foundation, Inc., 59 Temple Place - Suite 330,
21 Boston, MA 02111-1307, USA. */
23 /* As a special exception, when this file is copied by Bison into a
24 Bison output file, you may use that output file without restriction.
25 This special exception was added by the Free Software Foundation
26 in version 1.24 of Bison. */
28 /* This is the parser code that is written into each bison parser when
29 the %semantic_parser declaration is not specified in the grammar.
30 It was written by Richard Stallman by simplifying the original so
31 called ``semantic'' parser. */
33 /* All symbols defined below should begin with yy or YY, to avoid
34 infringing on user name space. This should be done even for local
35 variables, as they might otherwise be expanded by user macros.
36 There are some unavoidable exceptions within include files to
37 define necessary library symbols; they are noted "INFRINGES ON
38 USER NAME SPACE" below. */
40 /* Identify Bison output. */
46 /* Using locations. */
47 #define YYLSP_NEEDED 1
49 /* If NAME_PREFIX is specified substitute the variables and functions
51 #define yyparse gram_parse
52 #define yylex gram_lex
53 #define yyerror gram_error
54 #define yylval gram_lval
55 #define yychar gram_char
56 #define yydebug gram_debug
57 #define yynerrs gram_nerrs
59 # define yylloc gram_lloc
63 /* Copy the first part of user declarations. */
64 #line 31 "parse-gram.y"
67 #include "muscle_tab.h"
74 #include "conflicts.h"
76 /* Produce verbose parse errors. */
77 #define YYERROR_VERBOSE 1
78 #define YYLLOC_DEFAULT(Current, Rhs, N) \
82 Current.first_column = Rhs[1].first_column; \
83 Current.first_line = Rhs[1].first_line; \
84 Current.last_column = Rhs[N].last_column; \
85 Current.last_line = Rhs[N].last_line; \
93 /* Pass the control structure to YYPARSE and YYLEX. */
94 #define YYPARSE_PARAM gram_control
95 #define YYLEX_PARAM gram_control
96 /* YYPARSE receives GRAM_CONTROL as a void *. Provide a
97 correctly typed access to it. */
98 #define yycontrol ((gram_control_t *) gram_control)
100 /* Request detailed parse error messages, and pass them to
103 #define yyerror(Msg) \
104 gram_error (yycontrol, &yylloc, Msg)
106 /* When debugging our pure parser, we want to see values and locations
108 #define YYPRINT(File, Type, Value) \
109 yyprint (File, &yylloc, Type, &Value)
110 static void yyprint (FILE *file
, const location_t
*loc
,
111 int type
, const yystype
*value
);
113 symbol_class current_class
= unknown_sym
;
114 char *current_type
= 0;
115 symbol_t
*current_lhs
;
116 location_t current_lhs_location
;
117 associativity current_assoc
;
118 int current_prec
= 0;
123 # if defined (__STDC__) || defined (__cplusplus)
124 /* Put the tokens into the symbol table, so that GDB and other debuggers
137 PERCENT_NONASSOC
= 267,
138 PERCENT_EXPECT
= 268,
141 PERCENT_VERBOSE
= 271,
142 PERCENT_ERROR_VERBOSE
= 272,
143 PERCENT_OUTPUT
= 273,
144 PERCENT_FILE_PREFIX
= 274,
145 PERCENT_NAME_PREFIX
= 275,
146 PERCENT_DEFINE
= 276,
147 PERCENT_PURE_PARSER
= 277,
148 PERCENT_DEFINES
= 278,
151 PERCENT_LOCATIONS
= 281,
152 PERCENT_NO_LINES
= 282,
153 PERCENT_SKELETON
= 283,
154 PERCENT_TOKEN_TABLE
= 284,
161 PERCENT_PERCENT
= 291,
167 /* POSIX requires `int' for tokens in interfaces. */
168 # define YYTOKENTYPE int
169 #endif /* !YYTOKENTYPE */
172 #define CHARACTER 259
174 #define PERCENT_TOKEN 261
175 #define PERCENT_NTERM 262
176 #define PERCENT_TYPE 263
177 #define PERCENT_UNION 264
178 #define PERCENT_LEFT 265
179 #define PERCENT_RIGHT 266
180 #define PERCENT_NONASSOC 267
181 #define PERCENT_EXPECT 268
182 #define PERCENT_START 269
183 #define PERCENT_PREC 270
184 #define PERCENT_VERBOSE 271
185 #define PERCENT_ERROR_VERBOSE 272
186 #define PERCENT_OUTPUT 273
187 #define PERCENT_FILE_PREFIX 274
188 #define PERCENT_NAME_PREFIX 275
189 #define PERCENT_DEFINE 276
190 #define PERCENT_PURE_PARSER 277
191 #define PERCENT_DEFINES 278
192 #define PERCENT_YACC 279
193 #define PERCENT_DEBUG 280
194 #define PERCENT_LOCATIONS 281
195 #define PERCENT_NO_LINES 282
196 #define PERCENT_SKELETON 283
197 #define PERCENT_TOKEN_TABLE 284
200 #define SEMICOLON 287
204 #define PERCENT_PERCENT 291
207 #define BRACED_CODE 294
212 /* Enabling traces. */
217 /* Enabling verbose error messages. */
218 #ifdef YYERROR_VERBOSE
219 # undef YYERROR_VERBOSE
220 # define YYERROR_VERBOSE 1
222 # define YYERROR_VERBOSE 0
226 #line 90 "parse-gram.y"
234 /* Line 199 of /usr/local/share/bison/bison.simple. */
235 #line 236 "parse-gram.c"
236 # define YYSTYPE yystype
237 # define YYSTYPE_IS_TRIVIAL 1
241 typedef struct yyltype
248 # define YYLTYPE yyltype
249 # define YYLTYPE_IS_TRIVIAL 1
252 /* Copy the second part of user declarations. */
255 /* Line 219 of /usr/local/share/bison/bison.simple. */
256 #line 257 "parse-gram.c"
258 #if ! defined (yyoverflow) || YYERROR_VERBOSE
260 /* The parser invokes alloca or malloc; define the necessary symbols. */
262 # if YYSTACK_USE_ALLOCA
263 # define YYSTACK_ALLOC alloca
265 # ifndef YYSTACK_USE_ALLOCA
266 # if defined (alloca) || defined (_ALLOCA_H)
267 # define YYSTACK_ALLOC alloca
270 # define YYSTACK_ALLOC __builtin_alloca
276 # ifdef YYSTACK_ALLOC
277 /* Pacify GCC's `empty if-body' warning. */
278 # define YYSTACK_FREE(Ptr) do { /* empty */; } while (0)
280 # if defined (__STDC__) || defined (__cplusplus)
281 # include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
282 # define YYSIZE_T size_t
284 # define YYSTACK_ALLOC malloc
285 # define YYSTACK_FREE free
287 #endif /* ! defined (yyoverflow) || YYERROR_VERBOSE */
290 #if (! defined (yyoverflow) \
291 && (! defined (__cplusplus) \
292 || (YYLTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL)))
294 /* A type that is properly aligned for any stack member. */
304 /* The size of the maximum gap between one aligned stack and the next. */
305 # define YYSTACK_GAP_MAX (sizeof (union yyalloc) - 1)
307 /* The size of an array large to enough to hold all stacks, each with
310 # define YYSTACK_BYTES(N) \
311 ((N) * (sizeof (short) + sizeof (YYSTYPE) + sizeof (YYLTYPE)) \
312 + 2 * YYSTACK_GAP_MAX)
314 # define YYSTACK_BYTES(N) \
315 ((N) * (sizeof (short) + sizeof (YYSTYPE)) \
319 /* Copy COUNT objects from FROM to TO. The source and destination do
323 # define YYCOPY(To, From, Count) \
324 __builtin_memcpy (To, From, (Count) * sizeof (*(From)))
326 # define YYCOPY(To, From, Count) \
329 register YYSIZE_T yyi; \
330 for (yyi = 0; yyi < (Count); yyi++) \
331 (To)[yyi] = (From)[yyi]; \
337 /* Relocate STACK from its old location to the new one. The
338 local variables YYSIZE and YYSTACKSIZE give the old and new number of
339 elements in the stack, and YYPTR gives the new location of the
340 stack. Advance YYPTR to a properly aligned location for the next
342 # define YYSTACK_RELOCATE(Stack) \
345 YYSIZE_T yynewbytes; \
346 YYCOPY (&yyptr->Stack, Stack, yysize); \
347 Stack = &yyptr->Stack; \
348 yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAX; \
349 yyptr += yynewbytes / sizeof (*yyptr); \
355 /* YYFINAL -- State number of the termination state. */
357 #define YYFLAG -32768
360 /* YYNTOKENS -- Number of terminals. */
362 /* YYNNTS -- Number of nonterminals. */
364 /* YYNRULES -- Number of rules. */
366 /* YYNRULES -- Number of states. */
369 /* YYTRANSLATE(YYLEX) -- Bison symbol number corresponding to YYLEX. */
371 #define YYMAXUTOK 294
373 #define YYTRANSLATE(X) \
374 ((unsigned)(X) <= YYMAXUTOK ? yytranslate[X] : YYUNDEFTOK)
376 /* YYTRANSLATE[YYLEX] -- Bison symbol number corresponding to YYLEX. */
377 static const unsigned char yytranslate
[] =
379 0, 2, 2, 2, 2, 2, 2, 2, 2, 2,
380 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
381 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
382 2, 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, 1, 2, 3, 4,
405 5, 6, 7, 8, 9, 10, 11, 12, 13, 14,
406 15, 16, 17, 18, 19, 20, 21, 22, 23, 24,
407 25, 26, 27, 28, 29, 30, 31, 32, 33, 34,
412 /* YYPRHS[YYN] -- Index of the first RHS symbol of rule number YYN in
414 static const unsigned char yyprhs
[] =
416 0, 0, 3, 8, 9, 13, 15, 17, 19, 23,
417 25, 27, 30, 34, 36, 40, 42, 46, 48, 51,
418 53, 55, 57, 59, 61, 64, 67, 68, 72, 73,
419 77, 81, 85, 87, 89, 91, 92, 94, 96, 99,
420 101, 103, 106, 109, 113, 115, 118, 120, 123, 125,
421 128, 129, 135, 137, 141, 142, 145, 148, 152, 154,
422 156, 158, 160, 162, 164, 165, 168, 169
425 /* YYRHS -- A `-1'-separated list of the rules' RHS. */
426 static const signed char yyrhs
[] =
428 41, 0, -1, 42, 36, 54, 64, -1, -1, 42,
429 43, 65, -1, 44, -1, 37, -1, 25, -1, 21,
430 63, 63, -1, 23, -1, 17, -1, 13, 5, -1,
431 19, 31, 63, -1, 26, -1, 20, 31, 63, -1,
432 27, -1, 18, 31, 63, -1, 22, -1, 28, 63,
433 -1, 29, -1, 16, -1, 24, -1, 48, -1, 45,
434 -1, 14, 60, -1, 9, 39, -1, -1, 7, 46,
435 53, -1, -1, 6, 47, 53, -1, 8, 30, 51,
436 -1, 49, 50, 51, -1, 10, -1, 11, -1, 12,
437 -1, -1, 30, -1, 60, -1, 51, 60, -1, 30,
438 -1, 35, -1, 35, 5, -1, 35, 62, -1, 35,
439 5, 62, -1, 52, -1, 53, 52, -1, 55, -1,
440 54, 55, -1, 56, -1, 44, 32, -1, -1, 35,
441 33, 57, 58, 32, -1, 59, -1, 58, 34, 59,
442 -1, -1, 59, 60, -1, 59, 61, -1, 59, 15,
443 60, -1, 35, -1, 62, -1, 4, -1, 39, -1,
444 3, -1, 3, -1, -1, 36, 38, -1, -1, 32,
448 /* YYRLINE[YYN] -- source line where rule number YYN was defined. */
449 static const unsigned short yyrline
[] =
451 0, 152, 152, 165, 167, 170, 172, 173, 174, 175,
452 176, 177, 178, 179, 180, 181, 182, 183, 184, 185,
453 186, 187, 190, 192, 193, 197, 205, 205, 211, 211,
454 216, 225, 240, 242, 243, 246, 248, 253, 255, 259,
455 264, 269, 275, 281, 291, 294, 303, 305, 311, 313,
456 316, 316, 321, 323, 326, 329, 331, 333, 337, 339,
457 340, 343, 349, 358, 366, 371, 377, 379
461 #if YYDEBUG || YYERROR_VERBOSE
462 /* YYTNME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM.
463 First, the terminals, then, starting at YYNTOKENS, nonterminals. */
464 static const char *const yytname
[] =
466 "\"end of string\"", "error", "$undefined.", "STRING", "CHARACTER", "INT",
467 "\"%token\"", "\"%nterm\"", "\"%type\"", "\"%union\"", "\"%left\"",
468 "\"%right\"", "\"%nonassoc\"", "\"%expect\"", "\"%start\"", "\"%prec\"",
469 "\"%verbose\"", "\"%error-verbose\"", "\"%output\"", "\"%file-prefix\"",
470 "\"%name-prefix\"", "\"%define\"", "\"%pure-parser\"", "\"%defines\"",
471 "\"%yacc\"", "\"%debug\"", "\"%locations\"", "\"%no-lines\"",
472 "\"%skeleton\"", "\"%token-table\"", "TYPE", "\"=\"", "\";\"", "\":\"",
473 "\"|\"", "\"identifier\"", "\"%%\"", "PROLOGUE", "EPILOGUE",
474 "BRACED_CODE", "$axiom", "input", "declarations", "declaration",
475 "grammar_declaration", "symbol_declaration", "@1", "@2",
476 "precedence_declaration", "precedence_declarator", "type.opt",
477 "symbols.1", "symbol_def", "symbol_defs.1", "grammar",
478 "rules_or_grammar_declaration", "rules", "@3", "rhses.1", "rhs",
479 "symbol", "action", "string_as_id", "string_content", "epilogue.opt",
484 /* YYTOKNUM[YYLEX-NUM] -- Internal token number corresponding to
486 static const short yytoknum
[] =
488 0, 256, 257, 258, 259, 260, 261, 262, 263, 264,
489 265, 266, 267, 268, 269, 270, 271, 272, 273, 274,
490 275, 276, 277, 278, 279, 280, 281, 282, 283, 284,
491 285, 286, 287, 288, 289, 290, 291, 292, 293, 294,
495 /* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */
496 static const unsigned char yyr1
[] =
498 0, 40, 41, 42, 42, 43, 43, 43, 43, 43,
499 43, 43, 43, 43, 43, 43, 43, 43, 43, 43,
500 43, 43, 44, 44, 44, 44, 46, 45, 47, 45,
501 45, 48, 49, 49, 49, 50, 50, 51, 51, 52,
502 52, 52, 52, 52, 53, 53, 54, 54, 55, 55,
503 57, 56, 58, 58, 59, 59, 59, 59, 60, 60,
504 60, 61, 62, 63, 64, 64, 65, 65
507 /* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN. */
508 static const unsigned char yyr2
[] =
510 0, 2, 4, 0, 3, 1, 1, 1, 3, 1,
511 1, 2, 3, 1, 3, 1, 3, 1, 2, 1,
512 1, 1, 1, 1, 2, 2, 0, 3, 0, 3,
513 3, 3, 1, 1, 1, 0, 1, 1, 2, 1,
514 1, 2, 2, 3, 1, 2, 1, 2, 1, 2,
515 0, 5, 1, 3, 0, 2, 2, 3, 1, 1,
516 1, 1, 1, 1, 0, 2, 0, 1
519 /* YYDEFACT[STATE-NAME] -- Default rule to reduce with in state
520 STATE-NUM when YYTABLE doesn't specify something else to do. Zero
521 means the default is an error. */
522 static const short yydefact
[] =
524 3, 0, 0, 0, 28, 26, 0, 0, 32, 33,
525 34, 0, 0, 20, 10, 0, 0, 0, 0, 17,
526 9, 21, 7, 13, 15, 0, 19, 0, 6, 66,
527 5, 23, 22, 35, 0, 0, 0, 25, 11, 62,
528 60, 58, 24, 59, 0, 0, 0, 63, 0, 18,
529 0, 0, 64, 46, 48, 67, 4, 36, 0, 39,
530 40, 44, 29, 27, 30, 37, 16, 12, 14, 8,
531 50, 49, 0, 47, 2, 31, 41, 42, 45, 38,
532 54, 65, 43, 0, 52, 51, 54, 0, 61, 55,
536 /* YYPGOTO[NTERM-NUM]. */
537 static const short yydefgoto
[] =
539 -1, 1, 2, 29, 51, 31, 35, 34, 32, 33,
540 58, 64, 61, 62, 52, 53, 54, 80, 83, 84,
541 65, 90, 43, 48, 74, 56
544 /* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing
546 static const short yypact
[] =
548 -32768, 23, 74,-32768,-32768,-32768, 1, -31,-32768,-32768,
549 -32768, 29, 0,-32768,-32768, 7, 10, 14, 39,-32768,
550 -32768,-32768,-32768,-32768,-32768, 39,-32768, 18,-32768, 15,
551 -32768,-32768,-32768, 16, -24, -24, 0,-32768,-32768,-32768,
552 -32768,-32768,-32768,-32768, 39, 39, 39,-32768, 39,-32768,
553 17, 19, 8,-32768,-32768,-32768,-32768,-32768, 0,-32768,
554 4,-32768, -24, -24, 0,-32768,-32768,-32768,-32768,-32768,
555 -32768,-32768, 20,-32768,-32768, 0, 45,-32768,-32768,-32768,
556 -32768,-32768,-32768, -22, -2,-32768,-32768, 0,-32768,-32768,
560 /* YYPGOTO[NTERM-NUM]. */
561 static const short yypgoto
[] =
563 -32768,-32768,-32768,-32768, 47,-32768,-32768,-32768,-32768,-32768,
564 -32768, -4, -23, 25,-32768, 9,-32768,-32768,-32768, -21,
565 -12,-32768, -55, 11,-32768,-32768
568 /* YYTABLE[YYPACT[STATE-NUM]]. What to do in state STATE-NUM. If
569 positive, shift that token. If negative, reduce the rule which
570 number is the opposite. If zero, do what YYDEFACT says. */
571 static const short yytable
[] =
573 42, 39, 40, 39, 40, 77, 59, 39, 37, 76,
574 85, 60, 86, 87, 4, 5, 6, 7, 8, 9,
575 10, 82, 12, 3, 4, 5, 6, 7, 8, 9,
576 10, 36, 12, 41, 38, 41, 49, 88, 44, 78,
577 78, 45, 47, 50, 72, 46, 57, 55, 39, 30,
578 70, 71, 79, 50, 75, 66, 67, 68, 81, 69,
579 63, 73, 0, 79, 0, 91, 0, 0, 0, 0,
580 0, 0, 89, 0, 0, 92, 0, 0, 0, 89,
581 4, 5, 6, 7, 8, 9, 10, 11, 12, 0,
582 13, 14, 15, 16, 17, 18, 19, 20, 21, 22,
583 23, 24, 25, 26, 0, 0, 0, 0, 0, 0,
587 static const short yycheck
[] =
589 12, 3, 4, 3, 4, 60, 30, 3, 39, 5,
590 32, 35, 34, 15, 6, 7, 8, 9, 10, 11,
591 12, 76, 14, 0, 6, 7, 8, 9, 10, 11,
592 12, 30, 14, 35, 5, 35, 25, 39, 31, 62,
593 63, 31, 3, 35, 36, 31, 30, 32, 3, 2,
594 33, 32, 64, 35, 58, 44, 45, 46, 38, 48,
595 35, 52, -1, 75, -1, 86, -1, -1, -1, -1,
596 -1, -1, 84, -1, -1, 87, -1, -1, -1, 91,
597 6, 7, 8, 9, 10, 11, 12, 13, 14, -1,
598 16, 17, 18, 19, 20, 21, 22, 23, 24, 25,
599 26, 27, 28, 29, -1, -1, -1, -1, -1, -1,
604 /* YYSTOS[STATE-NUM] -- The (internal number of the) accessing
605 symbol of state STATE-NUM. */
606 static const unsigned char yystos
[] =
608 0, 41, 42, 0, 6, 7, 8, 9, 10, 11,
609 12, 13, 14, 16, 17, 18, 19, 20, 21, 22,
610 23, 24, 25, 26, 27, 28, 29, 36, 37, 43,
611 44, 45, 48, 49, 47, 46, 30, 39, 5, 3,
612 4, 35, 60, 62, 31, 31, 31, 3, 63, 63,
613 35, 44, 54, 55, 56, 32, 65, 30, 50, 30,
614 35, 52, 53, 53, 51, 60, 63, 63, 63, 63,
615 33, 32, 36, 55, 64, 51, 5, 62, 52, 60,
616 57, 38, 62, 58, 59, 32, 34, 15, 39, 60,
621 #if ! defined (YYSIZE_T) && defined (__SIZE_TYPE__)
622 # define YYSIZE_T __SIZE_TYPE__
624 #if ! defined (YYSIZE_T) && defined (size_t)
625 # define YYSIZE_T size_t
627 #if ! defined (YYSIZE_T)
628 # if defined (__STDC__) || defined (__cplusplus)
629 # include <stddef.h> /* INFRINGES ON USER NAME SPACE */
630 # define YYSIZE_T size_t
633 #if ! defined (YYSIZE_T)
634 # define YYSIZE_T unsigned int
637 #define yyerrok (yyerrstatus = 0)
638 #define yyclearin (yychar = YYEMPTY)
642 #define YYACCEPT goto yyacceptlab
643 #define YYABORT goto yyabortlab
644 #define YYERROR goto yyerrlab1
646 /* Like YYERROR except do call yyerror. This remains here temporarily
647 to ease the transition to the new meaning of YYERROR, for GCC.
648 Once GCC version 2 has supplanted version 1, this can go. */
650 #define YYFAIL goto yyerrlab
652 #define YYRECOVERING() (!!yyerrstatus)
654 #define YYBACKUP(Token, Value) \
656 if (yychar == YYEMPTY && yylen == 1) \
660 yychar1 = YYTRANSLATE (yychar); \
666 yyerror ("syntax error: cannot back up"); \
672 #define YYERRCODE 256
674 /* YYLLOC_DEFAULT -- Compute the default location (before the actions
677 #ifndef YYLLOC_DEFAULT
678 # define YYLLOC_DEFAULT(Current, Rhs, N) \
679 Current.first_line = Rhs[1].first_line; \
680 Current.first_column = Rhs[1].first_column; \
681 Current.last_line = Rhs[N].last_line; \
682 Current.last_column = Rhs[N].last_column;
685 /* YYLEX -- calling `yylex' with the right arguments. */
690 # define YYLEX yylex (&yylval, &yylloc, YYLEX_PARAM)
692 # define YYLEX yylex (&yylval, &yylloc)
694 # else /* !YYLSP_NEEDED */
696 # define YYLEX yylex (&yylval, YYLEX_PARAM)
698 # define YYLEX yylex (&yylval)
700 # endif /* !YYLSP_NEEDED */
702 # define YYLEX yylex ()
705 /* Enable debugging if requested. */
709 # include <stdio.h> /* INFRINGES ON USER NAME SPACE */
710 # define YYFPRINTF fprintf
713 # define YYDPRINTF(Args) \
718 /* Nonzero means print parse trace. It is left uninitialized so that
719 multiple parsers can coexist. */
722 # define YYDPRINTF(Args)
723 #endif /* !YYDEBUG */
725 /* YYINITDEPTH -- initial size of the parser's stacks. */
727 # define YYINITDEPTH 200
730 /* YYMAXDEPTH -- maximum size the stacks can grow to (effective only
731 if the built-in stack extension method is used).
733 Do not make this value too large; the results are undefined if
734 SIZE_MAX < YYSTACK_BYTES (YYMAXDEPTH)
735 evaluated with infinite-precision integer arithmetic. */
742 # define YYMAXDEPTH 10000
750 # if defined (__GLIBC__) && defined (_STRING_H)
751 # define yystrlen strlen
753 /* Return the length of YYSTR. */
755 # if defined (__STDC__) || defined (__cplusplus)
756 yystrlen (const char *yystr
)
762 register const char *yys
= yystr
;
764 while (*yys
++ != '\0')
767 return yys
- yystr
- 1;
773 # if defined (__GLIBC__) && defined (_STRING_H) && defined (_GNU_SOURCE)
774 # define yystpcpy stpcpy
776 /* Copy YYSRC to YYDEST, returning the address of the terminating '\0' in
779 # if defined (__STDC__) || defined (__cplusplus)
780 yystpcpy (char *yydest
, const char *yysrc
)
782 yystpcpy (yydest
, yysrc
)
787 register char *yyd
= yydest
;
788 register const char *yys
= yysrc
;
790 while ((*yyd
++ = *yys
++) != '\0')
798 #endif /* !YYERROR_VERBOSE */
802 /* The user can define YYPARSE_PARAM as the name of an argument to be passed
803 into yyparse. The argument should have type void *.
804 It should actually point to an object.
805 Grammar actions can access the variable by casting it
806 to the proper pointer type. */
809 # if defined (__STDC__) || defined (__cplusplus)
810 # define YYPARSE_PARAM_ARG void *YYPARSE_PARAM
811 # define YYPARSE_PARAM_DECL
813 # define YYPARSE_PARAM_ARG YYPARSE_PARAM
814 # define YYPARSE_PARAM_DECL void *YYPARSE_PARAM;
816 #else /* !YYPARSE_PARAM */
817 # define YYPARSE_PARAM_ARG
818 # define YYPARSE_PARAM_DECL
819 #endif /* !YYPARSE_PARAM */
821 /* Prevent warning if -Wstrict-prototypes. */
823 # ifdef YYPARSE_PARAM
824 int yyparse (void *);
830 /* YY_DECL_VARIABLES -- depending whether we use a pure parser,
831 variables are global, or local to YYPARSE. */
833 #define YY_DECL_NON_LSP_VARIABLES \
834 /* The lookahead symbol. */ \
837 /* The semantic value of the lookahead symbol. */ \
840 /* Number of parse errors so far. */ \
844 # define YY_DECL_VARIABLES \
845 YY_DECL_NON_LSP_VARIABLES \
847 /* Location data for the lookahead symbol. */ \
850 # define YY_DECL_VARIABLES \
851 YY_DECL_NON_LSP_VARIABLES
854 /* If nonreentrant, generate the variables here. */
861 yyparse (YYPARSE_PARAM_ARG
)
864 /* If reentrant, generate the variables here. */
869 register int yystate
;
872 /* Number of tokens to shift before error messages enabled. */
874 /* Lookahead token as an internal (translated) token number. */
877 /* Three stacks and their tools:
878 `yyss': related to states,
879 `yyvs': related to semantic values,
880 `yyls': related to locations.
882 Refer to the stacks thru separate pointers, to allow yyoverflow
883 to reallocate them elsewhere. */
885 /* The state stack. */
886 short yyssa
[YYINITDEPTH
];
888 register short *yyssp
;
890 /* The semantic value stack. */
891 YYSTYPE yyvsa
[YYINITDEPTH
];
892 YYSTYPE
*yyvs
= yyvsa
;
893 register YYSTYPE
*yyvsp
;
896 /* The location stack. */
897 YYLTYPE yylsa
[YYINITDEPTH
];
898 YYLTYPE
*yyls
= yylsa
;
903 # define YYPOPSTACK (yyvsp--, yyssp--, yylsp--)
905 # define YYPOPSTACK (yyvsp--, yyssp--)
908 YYSIZE_T yystacksize
= YYINITDEPTH
;
910 /* The variables used to return semantic value and location from the
917 /* When reducing, the number of symbols on the RHS of the reduced
921 YYDPRINTF ((stderr
, "Starting parse\n"));
926 yychar
= YYEMPTY
; /* Cause a token to be read. */
928 /* Initialize stack pointers.
929 Waste one element of value and location stack
930 so that they stay on the same level as the state stack.
931 The wasted elements are never initialized. */
940 /*------------------------------------------------------------.
941 | yynewstate -- Push a new state, which is found in yystate. |
942 `------------------------------------------------------------*/
944 /* In all cases, when you get here, the value and location stacks
945 have just been pushed. so pushing a state here evens the stacks.
952 if (yyssp
>= yyss
+ yystacksize
- 1)
954 /* Get the current used size of the three stacks, in elements. */
955 YYSIZE_T yysize
= yyssp
- yyss
+ 1;
959 /* Give user a chance to reallocate the stack. Use copies of
960 these so that the &'s don't force the real ones into
962 YYSTYPE
*yyvs1
= yyvs
;
965 /* Each stack pointer address is followed by the size of the
966 data in use in that stack, in bytes. */
968 YYLTYPE
*yyls1
= yyls
;
969 /* This used to be a conditional around just the two extra args,
970 but that might be undefined if yyoverflow is a macro. */
971 yyoverflow ("parser stack overflow",
972 &yyss1
, yysize
* sizeof (*yyssp
),
973 &yyvs1
, yysize
* sizeof (*yyvsp
),
974 &yyls1
, yysize
* sizeof (*yylsp
),
978 yyoverflow ("parser stack overflow",
979 &yyss1
, yysize
* sizeof (*yyssp
),
980 &yyvs1
, yysize
* sizeof (*yyvsp
),
986 #else /* no yyoverflow */
987 # ifndef YYSTACK_RELOCATE
990 /* Extend the stack our own way. */
991 if (yystacksize
>= YYMAXDEPTH
)
994 if (yystacksize
> YYMAXDEPTH
)
995 yystacksize
= YYMAXDEPTH
;
999 union yyalloc
*yyptr
=
1000 (union yyalloc
*) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize
));
1003 YYSTACK_RELOCATE (yyss
);
1004 YYSTACK_RELOCATE (yyvs
);
1006 YYSTACK_RELOCATE (yyls
);
1008 # undef YYSTACK_RELOCATE
1010 YYSTACK_FREE (yyss1
);
1013 #endif /* no yyoverflow */
1015 yyssp
= yyss
+ yysize
- 1;
1016 yyvsp
= yyvs
+ yysize
- 1;
1018 yylsp
= yyls
+ yysize
- 1;
1021 YYDPRINTF ((stderr
, "Stack size increased to %lu\n",
1022 (unsigned long int) yystacksize
));
1024 if (yyssp
>= yyss
+ yystacksize
- 1)
1028 YYDPRINTF ((stderr
, "Entering state %d\n", yystate
));
1037 /* Do appropriate processing given the current state. */
1038 /* Read a lookahead token if we need one and don't already have one. */
1041 /* First try to decide what to do without reference to lookahead token. */
1043 yyn
= yypact
[yystate
];
1047 /* Not known => get a lookahead token if don't already have one. */
1049 /* yychar is either YYEMPTY or YYEOF
1050 or a valid token in external form. */
1052 if (yychar
== YYEMPTY
)
1054 YYDPRINTF ((stderr
, "Reading a token: "));
1058 /* Convert token to internal form (in yychar1) for indexing tables with. */
1060 if (yychar
<= 0) /* This means end of input. */
1063 yychar
= YYEOF
; /* Don't call YYLEX any more. */
1065 YYDPRINTF ((stderr
, "Now at end of input.\n"));
1069 yychar1
= YYTRANSLATE (yychar
);
1072 /* We have to keep this `#if YYDEBUG', since we use variables
1073 which are defined only if `YYDEBUG' is set. */
1076 YYFPRINTF (stderr
, "Next token is %d (%s",
1077 yychar
, yytname
[yychar1
]);
1078 /* Give the individual parser a way to print the precise
1079 meaning of a token, for further debugging info. */
1081 YYPRINT (stderr
, yychar
, yylval
);
1083 YYFPRINTF (stderr
, ")\n");
1089 if (yyn
< 0 || yyn
> YYLAST
|| yycheck
[yyn
] != yychar1
)
1094 /* yyn is what to do for this token type in this state.
1095 Negative => reduce, -yyn is rule number.
1096 Positive => shift, yyn is new state.
1097 New state is final state => don't bother to shift,
1098 just return success.
1099 0, or most negative number => error. */
1114 /* Shift the lookahead token. */
1115 YYDPRINTF ((stderr
, "Shifting token %d (%s), ",
1116 yychar
, yytname
[yychar1
]));
1118 /* Discard the token being shifted unless it is eof. */
1119 if (yychar
!= YYEOF
)
1127 /* Count tokens shifted since error; after three, turn off error
1136 /*-----------------------------------------------------------.
1137 | yydefault -- do the default action for the current state. |
1138 `-----------------------------------------------------------*/
1140 yyn
= yydefact
[yystate
];
1146 /*-----------------------------.
1147 | yyreduce -- Do a reduction. |
1148 `-----------------------------*/
1150 /* yyn is the number of a rule to reduce with. */
1153 /* If YYLEN is nonzero, implement the default value of the action:
1156 Otherwise, the following line sets YYVAL to the semantic value of
1157 the lookahead token. This behavior is undocumented and Bison
1158 users should not rely upon it. Assigning to YYVAL
1159 unconditionally makes the parser a bit smaller, and it avoids a
1160 GCC warning that YYVAL may be used uninitialized. */
1161 yyval
= yyvsp
[1-yylen
];
1164 /* Default location. */
1165 YYLLOC_DEFAULT (yyloc
, (yylsp
- yylen
), yylen
);
1169 /* We have to keep this `#if YYDEBUG', since we use variables which
1170 are defined only if `YYDEBUG' is set. */
1175 YYFPRINTF (stderr
, "Reducing via rule %d (line %d), ",
1176 yyn
- 1, yyrline
[yyn
]);
1178 /* Print the symbols being reduced, and their result. */
1179 for (yyi
= yyprhs
[yyn
]; yyrhs
[yyi
] >= 0; yyi
++)
1180 YYFPRINTF (stderr
, "%s ", yytname
[yyrhs
[yyi
]]);
1181 YYFPRINTF (stderr
, " -> %s\n", yytname
[yyr1
[yyn
]]);
1187 #line 154 "parse-gram.y"
1189 yycontrol
->errcode
= 0;
1190 epilogue_set (yyvsp
[0].string
, yylsp
[0]);
1195 #line 172 "parse-gram.y"
1196 { prologue_augment (yyvsp
[0].string
, yylsp
[0]); }
1200 #line 173 "parse-gram.y"
1205 #line 174 "parse-gram.y"
1206 { muscle_insert (yyvsp
[-1].string
, yyvsp
[0].string
); }
1210 #line 175 "parse-gram.y"
1211 { defines_flag
= 1; }
1215 #line 176 "parse-gram.y"
1216 { error_verbose
= 1; }
1220 #line 177 "parse-gram.y"
1221 { expected_conflicts
= yyvsp
[0].integer
; }
1225 #line 178 "parse-gram.y"
1226 { spec_file_prefix
= yyvsp
[0].string
; }
1230 #line 179 "parse-gram.y"
1231 { locations_flag
= 1; }
1235 #line 180 "parse-gram.y"
1236 { spec_name_prefix
= yyvsp
[0].string
; }
1240 #line 181 "parse-gram.y"
1241 { no_lines_flag
= 1; }
1245 #line 182 "parse-gram.y"
1246 { spec_outfile
= yyvsp
[0].string
; }
1250 #line 183 "parse-gram.y"
1251 { pure_parser
= 1; }
1255 #line 184 "parse-gram.y"
1256 { skeleton
= yyvsp
[0].string
; }
1260 #line 185 "parse-gram.y"
1261 { token_table_flag
= 1; }
1265 #line 186 "parse-gram.y"
1266 { report_flag
= 1; }
1270 #line 187 "parse-gram.y"
1275 #line 194 "parse-gram.y"
1277 grammar_start_symbol_set (yyvsp
[0].symbol
, yylsp
[0]);
1282 #line 198 "parse-gram.y"
1285 MUSCLE_INSERT_INT ("stype_line", yylsp
[0].first_line
);
1286 muscle_insert ("stype", yyvsp
[0].string
);
1291 #line 206 "parse-gram.y"
1292 { current_class
= nterm_sym
; }
1296 #line 207 "parse-gram.y"
1298 current_class
= unknown_sym
;
1299 current_type
= NULL
;
1304 #line 211 "parse-gram.y"
1305 { current_class
= token_sym
; }
1309 #line 212 "parse-gram.y"
1311 current_class
= unknown_sym
;
1312 current_type
= NULL
;
1317 #line 217 "parse-gram.y"
1319 symbol_list_t
*list
;
1320 for (list
= yyvsp
[0].list
; list
; list
= list
->next
)
1321 symbol_type_set (list
->sym
, list
->location
, yyvsp
[-1].string
);
1322 symbol_list_free (yyvsp
[0].list
);
1327 #line 227 "parse-gram.y"
1329 symbol_list_t
*list
;
1331 for (list
= yyvsp
[0].list
; list
; list
= list
->next
)
1333 symbol_type_set (list
->sym
, list
->location
, current_type
);
1334 symbol_precedence_set (list
->sym
, list
->location
, current_prec
, yyvsp
[-2].assoc
);
1336 symbol_list_free (yyvsp
[0].list
);
1337 current_type
= NULL
;
1342 #line 241 "parse-gram.y"
1343 { yyval
.assoc
= left_assoc
; }
1347 #line 242 "parse-gram.y"
1348 { yyval
.assoc
= right_assoc
; }
1352 #line 243 "parse-gram.y"
1353 { yyval
.assoc
= non_assoc
; }
1357 #line 247 "parse-gram.y"
1358 { current_type
= NULL
;}
1362 #line 248 "parse-gram.y"
1363 { current_type
= yyvsp
[0].string
; }
1367 #line 254 "parse-gram.y"
1368 { yyval
.list
= symbol_list_new (yyvsp
[0].symbol
, yylsp
[0]); }
1372 #line 255 "parse-gram.y"
1373 { yyval
.list
= symbol_list_prepend (yyvsp
[-1].list
, yyvsp
[0].symbol
, yylsp
[0]); }
1377 #line 261 "parse-gram.y"
1379 current_type
= yyvsp
[0].string
;
1384 #line 265 "parse-gram.y"
1386 symbol_class_set (yyvsp
[0].symbol
, current_class
);
1387 symbol_type_set (yyvsp
[0].symbol
, yylsp
[0], current_type
);
1392 #line 270 "parse-gram.y"
1394 symbol_class_set (yyvsp
[-1].symbol
, current_class
);
1395 symbol_type_set (yyvsp
[-1].symbol
, yylsp
[-1], current_type
);
1396 symbol_user_token_number_set (yyvsp
[-1].symbol
, yyvsp
[0].integer
);
1401 #line 276 "parse-gram.y"
1403 symbol_class_set (yyvsp
[-1].symbol
, current_class
);
1404 symbol_type_set (yyvsp
[-1].symbol
, yylsp
[-1], current_type
);
1405 symbol_make_alias (yyvsp
[-1].symbol
, yyvsp
[0].symbol
);
1410 #line 282 "parse-gram.y"
1412 symbol_class_set (yyvsp
[-2].symbol
, current_class
);
1413 symbol_type_set (yyvsp
[-2].symbol
, yylsp
[-2], current_type
);
1414 symbol_user_token_number_set (yyvsp
[-2].symbol
, yyvsp
[-1].integer
);
1415 symbol_make_alias (yyvsp
[-2].symbol
, yyvsp
[0].symbol
);
1420 #line 293 "parse-gram.y"
1425 #line 295 "parse-gram.y"
1430 #line 317 "parse-gram.y"
1431 { current_lhs
= yyvsp
[-1].symbol
; current_lhs_location
= yylsp
[-1]; }
1435 #line 318 "parse-gram.y"
1440 #line 322 "parse-gram.y"
1441 { grammar_rule_end (yylsp
[0]); }
1445 #line 323 "parse-gram.y"
1446 { grammar_rule_end (yylsp
[0]); }
1450 #line 328 "parse-gram.y"
1451 { grammar_rule_begin (current_lhs
, current_lhs_location
); }
1455 #line 330 "parse-gram.y"
1456 { grammar_current_rule_symbol_append (yyvsp
[0].symbol
, yylsp
[0]); }
1460 #line 332 "parse-gram.y"
1461 { grammar_current_rule_action_append (yyvsp
[0].string
, yylsp
[0]); }
1465 #line 334 "parse-gram.y"
1466 { grammar_current_rule_prec_set (yyvsp
[0].symbol
); }
1470 #line 338 "parse-gram.y"
1471 { yyval
.symbol
= yyvsp
[0].symbol
; }
1475 #line 339 "parse-gram.y"
1476 { yyval
.symbol
= yyvsp
[0].symbol
; }
1480 #line 340 "parse-gram.y"
1481 { yyval
.symbol
= getsym (yyvsp
[0].string
, yylsp
[0]); }
1485 #line 345 "parse-gram.y"
1486 { yyval
.string
= yyvsp
[0].string
; }
1490 #line 351 "parse-gram.y"
1492 yyval
.symbol
= getsym (yyvsp
[0].string
, yylsp
[0]);
1493 symbol_class_set (yyval
.symbol
, token_sym
);
1498 #line 360 "parse-gram.y"
1500 yyval
.string
= yyvsp
[0].string
+ 1;
1501 yyval
.string
[strlen (yyval
.string
) - 1] = '\0';
1506 #line 368 "parse-gram.y"
1508 yyval
.string
= xstrdup ("");
1513 #line 372 "parse-gram.y"
1515 yyval
.string
= yyvsp
[0].string
;
1522 /* Line 1012 of /usr/local/share/bison/bison.simple. */
1523 #line 1524 "parse-gram.c"
1534 short *yyssp1
= yyss
- 1;
1535 YYFPRINTF (stderr
, "state stack now");
1536 while (yyssp1
!= yyssp
)
1537 YYFPRINTF (stderr
, " %d", *++yyssp1
);
1538 YYFPRINTF (stderr
, "\n");
1547 /* Now `shift' the result of the reduction. Determine what state
1548 that goes to, based on the state we popped back to and the rule
1549 number reduced by. */
1553 yystate
= yypgoto
[yyn
- YYNTOKENS
] + *yyssp
;
1554 if (yystate
>= 0 && yystate
<= YYLAST
&& yycheck
[yystate
] == *yyssp
)
1555 yystate
= yytable
[yystate
];
1557 yystate
= yydefgoto
[yyn
- YYNTOKENS
];
1562 /*------------------------------------.
1563 | yyerrlab -- here on detecting error |
1564 `------------------------------------*/
1566 /* If not already recovering from an error, report this error. */
1572 yyn
= yypact
[yystate
];
1574 if (yyn
> YYFLAG
&& yyn
< YYLAST
)
1576 YYSIZE_T yysize
= 0;
1581 /* Start YYX at -YYN if negative to avoid negative indexes in
1583 for (yyx
= yyn
< 0 ? -yyn
: 0;
1584 yyx
< (int) (sizeof (yytname
) / sizeof (char *)); yyx
++)
1585 if (yycheck
[yyx
+ yyn
] == yyx
)
1586 yysize
+= yystrlen (yytname
[yyx
]) + 15, yycount
++;
1587 yysize
+= yystrlen ("parse error, unexpected ") + 1;
1588 yysize
+= yystrlen (yytname
[YYTRANSLATE (yychar
)]);
1589 yymsg
= (char *) YYSTACK_ALLOC (yysize
);
1592 char *yyp
= yystpcpy (yymsg
, "parse error, unexpected ");
1593 yyp
= yystpcpy (yyp
, yytname
[YYTRANSLATE (yychar
)]);
1598 for (yyx
= yyn
< 0 ? -yyn
: 0;
1599 yyx
< (int) (sizeof (yytname
) / sizeof (char *));
1601 if (yycheck
[yyx
+ yyn
] == yyx
)
1603 const char *yyq
= ! yycount
? ", expecting " : " or ";
1604 yyp
= yystpcpy (yyp
, yyq
);
1605 yyp
= yystpcpy (yyp
, yytname
[yyx
]);
1610 YYSTACK_FREE (yymsg
);
1613 yyerror ("parse error; also virtual memory exhausted");
1616 #endif /* YYERROR_VERBOSE */
1617 yyerror ("parse error");
1622 /*----------------------------------------------------.
1623 | yyerrlab1 -- error raised explicitly by an action. |
1624 `----------------------------------------------------*/
1626 if (yyerrstatus
== 3)
1628 /* If just tried and failed to reuse lookahead token after an
1629 error, discard it. */
1631 /* Return failure if at end of input. */
1632 if (yychar
== YYEOF
)
1634 YYDPRINTF ((stderr
, "Discarding token %d (%s).\n",
1635 yychar
, yytname
[yychar1
]));
1639 /* Else will try to reuse lookahead token after shifting the error
1642 yyerrstatus
= 3; /* Each real token shifted decrements this. */
1646 yyn
= yypact
[yystate
];
1650 if (0 <= yyn
&& yyn
<= YYLAST
&& yycheck
[yyn
] == YYTERROR
)
1658 /* Pop the current state because it cannot handle the error token. */
1665 if (yystos
[yystate
] < YYNTOKENS
)
1667 YYFPRINTF (stderr
, "Error: popping token %d (%s",
1668 yytoknum
[yystos
[yystate
]], yytname
[yystos
[yystate
]]);
1670 YYPRINT (stderr
, yytoknum
[yystos
[yystate
]], *yyvsp
);
1672 YYFPRINTF (stderr
, ")\n");
1676 YYFPRINTF (stderr
, "Error: popping nonterminal (%s)\n",
1677 yytname
[yystos
[yystate
]]);
1691 short *yyssp1
= yyss
- 1;
1692 YYFPRINTF (stderr
, "Error: state stack now");
1693 while (yyssp1
!= yyssp
)
1694 YYFPRINTF (stderr
, " %d", *++yyssp1
);
1695 YYFPRINTF (stderr
, "\n");
1703 YYDPRINTF ((stderr
, "Shifting error token, "));
1714 /*-------------------------------------.
1715 | yyacceptlab -- YYACCEPT comes here. |
1716 `-------------------------------------*/
1721 /*-----------------------------------.
1722 | yyabortlab -- YYABORT comes here. |
1723 `-----------------------------------*/
1728 /*---------------------------------------------.
1729 | yyoverflowab -- parser overflow comes here. |
1730 `---------------------------------------------*/
1732 yyerror ("parser stack overflow");
1739 YYSTACK_FREE (yyss
);
1744 #line 381 "parse-gram.y"
1746 /*------------------------------------------------------------------.
1747 | When debugging the parser, display tokens' locations and values. |
1748 `------------------------------------------------------------------*/
1751 yyprint (FILE *file
,
1752 const location_t
*loc
, int type
, const yystype
*value
)
1755 LOCATION_PRINT (file
, *loc
);
1760 fprintf (file
, " = '%s'", value
->string
);
1764 fprintf (file
, " = %s", value
->symbol
->tag
);
1768 fprintf (file
, " = %d", value
->integer
);
1772 fprintf (file
, " = \"%s\"", value
->string
);
1776 fprintf (file
, " = <%s>", value
->string
);
1782 fprintf (file
, " = {{ %s }}", value
->string
);
1788 gram_error (gram_control_t
*control ATTRIBUTE_UNUSED
,
1789 location_t
*yylloc
, const char *msg
)
1791 LOCATION_PRINT (stderr
, *yylloc
);
1792 fprintf (stderr
, ": %s\n", msg
);