1 /* A Bison parser, made by GNU Bison 3.5. */
2
3 /* Bison implementation for Yacc-like parsers in C
4
5 Copyright (C) 1984, 1989-1990, 2000-2015, 2018-2019 Free Software Foundation,
6 Inc.
7
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 3 of the License, or
11 (at your option) any later version.
12
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.
17
18 You should have received a copy of the GNU General Public License
19 along with this program. If not, see <http://www.gnu.org/licenses/>. */
20
21 /* As a special exception, you may create a larger work that contains
22 part or all of the Bison parser skeleton and distribute that work
23 under terms of your choice, so long as that work isn't itself a
24 parser generator using the skeleton or a modified version thereof
25 as a parser skeleton. Alternatively, if you modify or redistribute
26 the parser skeleton itself, you may (at your option) remove this
27 special exception, which will cause the skeleton and the resulting
28 Bison output files to be licensed under the GNU General Public
29 License without this special exception.
30
31 This special exception was added by the Free Software Foundation in
32 version 2.2 of Bison. */
33
34 /* C LALR(1) parser skeleton written by Richard Stallman, by
35 simplifying the original so-called "semantic" parser. */
36
37 /* All symbols defined below should begin with yy or YY, to avoid
38 infringing on user name space. This should be done even for local
39 variables, as they might otherwise be expanded by user macros.
40 There are some unavoidable exceptions within include files to
41 define necessary library symbols; they are noted "INFRINGES ON
42 USER NAME SPACE" below. */
43
44 /* Undocumented macros, especially those whose name start with YY_,
45 are private implementation details. Do not rely on them. */
46
47 /* Identify Bison output. */
48 #define YYBISON 1
49
50 /* Bison version. */
51 #define YYBISON_VERSION "3.5"
52
53 /* Skeleton name. */
54 #define YYSKELETON_NAME "yacc.c"
55
56 /* Pure parsers. */
57 #define YYPURE 1
58
59 /* Push parsers. */
60 #define YYPUSH 0
61
62 /* Pull parsers. */
63 #define YYPULL 1
64
65
66
67
68 /* First part of user prologue. */
69 #line 26 "yyscript.y"
70
71
72 #include "config.h"
73
74 #include <stddef.h>
75 #include <stdint.h>
76 #include <stdlib.h>
77 #include <string.h>
78
79 #include "script-c.h"
80
81
82 #line 83 "yyscript.c"
83
84 # ifndef YY_CAST
85 # ifdef __cplusplus
86 # define YY_CAST(Type, Val) static_cast<Type> (Val)
87 # define YY_REINTERPRET_CAST(Type, Val) reinterpret_cast<Type> (Val)
88 # else
89 # define YY_CAST(Type, Val) ((Type) (Val))
90 # define YY_REINTERPRET_CAST(Type, Val) ((Type) (Val))
91 # endif
92 # endif
93 # ifndef YY_NULLPTR
94 # if defined __cplusplus
95 # if 201103L <= __cplusplus
96 # define YY_NULLPTR nullptr
97 # else
98 # define YY_NULLPTR 0
99 # endif
100 # else
101 # define YY_NULLPTR ((void*)0)
102 # endif
103 # endif
104
105 /* Enabling verbose error messages. */
106 #ifdef YYERROR_VERBOSE
107 # undef YYERROR_VERBOSE
108 # define YYERROR_VERBOSE 1
109 #else
110 # define YYERROR_VERBOSE 1
111 #endif
112
113 /* Use api.header.include to #include this header
114 instead of duplicating it here. */
115 #ifndef YY_YY_YYSCRIPT_H_INCLUDED
116 # define YY_YY_YYSCRIPT_H_INCLUDED
117 /* Debug traces. */
118 #ifndef YYDEBUG
119 # define YYDEBUG 0
120 #endif
121 #if YYDEBUG
122 extern int yydebug;
123 #endif
124
125 /* Token type. */
126 #ifndef YYTOKENTYPE
127 # define YYTOKENTYPE
128 enum yytokentype
129 {
130 PLUSEQ = 258,
131 MINUSEQ = 259,
132 MULTEQ = 260,
133 DIVEQ = 261,
134 LSHIFTEQ = 262,
135 RSHIFTEQ = 263,
136 ANDEQ = 264,
137 OREQ = 265,
138 OROR = 266,
139 ANDAND = 267,
140 EQ = 268,
141 NE = 269,
142 LE = 270,
143 GE = 271,
144 LSHIFT = 272,
145 RSHIFT = 273,
146 UNARY = 274,
147 STRING = 275,
148 QUOTED_STRING = 276,
149 INTEGER = 277,
150 ABSOLUTE = 278,
151 ADDR = 279,
152 ALIGN_K = 280,
153 ALIGNOF = 281,
154 ASSERT_K = 282,
155 AS_NEEDED = 283,
156 AT = 284,
157 BIND = 285,
158 BLOCK = 286,
159 BYTE = 287,
160 CONSTANT = 288,
161 CONSTRUCTORS = 289,
162 COPY = 290,
163 CREATE_OBJECT_SYMBOLS = 291,
164 DATA_SEGMENT_ALIGN = 292,
165 DATA_SEGMENT_END = 293,
166 DATA_SEGMENT_RELRO_END = 294,
167 DEFINED = 295,
168 DSECT = 296,
169 ENTRY = 297,
170 EXCLUDE_FILE = 298,
171 EXTERN = 299,
172 FILL = 300,
173 FLOAT = 301,
174 FORCE_COMMON_ALLOCATION = 302,
175 GLOBAL = 303,
176 GROUP = 304,
177 HIDDEN = 305,
178 HLL = 306,
179 INCLUDE = 307,
180 INHIBIT_COMMON_ALLOCATION = 308,
181 INFO = 309,
182 INPUT = 310,
183 KEEP = 311,
184 LEN = 312,
185 LENGTH = 313,
186 LOADADDR = 314,
187 LOCAL = 315,
188 LONG = 316,
189 MAP = 317,
190 MAX_K = 318,
191 MEMORY = 319,
192 MIN_K = 320,
193 NEXT = 321,
194 NOCROSSREFS = 322,
195 NOFLOAT = 323,
196 NOLOAD = 324,
197 ONLY_IF_RO = 325,
198 ONLY_IF_RW = 326,
199 ORG = 327,
200 ORIGIN = 328,
201 OUTPUT = 329,
202 OUTPUT_ARCH = 330,
203 OUTPUT_FORMAT = 331,
204 OVERLAY = 332,
205 PHDRS = 333,
206 PROVIDE = 334,
207 PROVIDE_HIDDEN = 335,
208 QUAD = 336,
209 SEARCH_DIR = 337,
210 SECTIONS = 338,
211 SEGMENT_START = 339,
212 SHORT = 340,
213 SIZEOF = 341,
214 SIZEOF_HEADERS = 342,
215 SORT_BY_ALIGNMENT = 343,
216 SORT_BY_INIT_PRIORITY = 344,
217 SORT_BY_NAME = 345,
218 SPECIAL = 346,
219 SQUAD = 347,
220 STARTUP = 348,
221 SUBALIGN = 349,
222 SYSLIB = 350,
223 TARGET_K = 351,
224 TRUNCATE = 352,
225 VERSIONK = 353,
226 OPTION = 354,
227 PARSING_LINKER_SCRIPT = 355,
228 PARSING_VERSION_SCRIPT = 356,
229 PARSING_DEFSYM = 357,
230 PARSING_DYNAMIC_LIST = 358,
231 PARSING_SECTIONS_BLOCK = 359,
232 PARSING_SECTION_COMMANDS = 360,
233 PARSING_MEMORY_DEF = 361
234 };
235 #endif
236 /* Tokens. */
237 #define PLUSEQ 258
238 #define MINUSEQ 259
239 #define MULTEQ 260
240 #define DIVEQ 261
241 #define LSHIFTEQ 262
242 #define RSHIFTEQ 263
243 #define ANDEQ 264
244 #define OREQ 265
245 #define OROR 266
246 #define ANDAND 267
247 #define EQ 268
248 #define NE 269
249 #define LE 270
250 #define GE 271
251 #define LSHIFT 272
252 #define RSHIFT 273
253 #define UNARY 274
254 #define STRING 275
255 #define QUOTED_STRING 276
256 #define INTEGER 277
257 #define ABSOLUTE 278
258 #define ADDR 279
259 #define ALIGN_K 280
260 #define ALIGNOF 281
261 #define ASSERT_K 282
262 #define AS_NEEDED 283
263 #define AT 284
264 #define BIND 285
265 #define BLOCK 286
266 #define BYTE 287
267 #define CONSTANT 288
268 #define CONSTRUCTORS 289
269 #define COPY 290
270 #define CREATE_OBJECT_SYMBOLS 291
271 #define DATA_SEGMENT_ALIGN 292
272 #define DATA_SEGMENT_END 293
273 #define DATA_SEGMENT_RELRO_END 294
274 #define DEFINED 295
275 #define DSECT 296
276 #define ENTRY 297
277 #define EXCLUDE_FILE 298
278 #define EXTERN 299
279 #define FILL 300
280 #define FLOAT 301
281 #define FORCE_COMMON_ALLOCATION 302
282 #define GLOBAL 303
283 #define GROUP 304
284 #define HIDDEN 305
285 #define HLL 306
286 #define INCLUDE 307
287 #define INHIBIT_COMMON_ALLOCATION 308
288 #define INFO 309
289 #define INPUT 310
290 #define KEEP 311
291 #define LEN 312
292 #define LENGTH 313
293 #define LOADADDR 314
294 #define LOCAL 315
295 #define LONG 316
296 #define MAP 317
297 #define MAX_K 318
298 #define MEMORY 319
299 #define MIN_K 320
300 #define NEXT 321
301 #define NOCROSSREFS 322
302 #define NOFLOAT 323
303 #define NOLOAD 324
304 #define ONLY_IF_RO 325
305 #define ONLY_IF_RW 326
306 #define ORG 327
307 #define ORIGIN 328
308 #define OUTPUT 329
309 #define OUTPUT_ARCH 330
310 #define OUTPUT_FORMAT 331
311 #define OVERLAY 332
312 #define PHDRS 333
313 #define PROVIDE 334
314 #define PROVIDE_HIDDEN 335
315 #define QUAD 336
316 #define SEARCH_DIR 337
317 #define SECTIONS 338
318 #define SEGMENT_START 339
319 #define SHORT 340
320 #define SIZEOF 341
321 #define SIZEOF_HEADERS 342
322 #define SORT_BY_ALIGNMENT 343
323 #define SORT_BY_INIT_PRIORITY 344
324 #define SORT_BY_NAME 345
325 #define SPECIAL 346
326 #define SQUAD 347
327 #define STARTUP 348
328 #define SUBALIGN 349
329 #define SYSLIB 350
330 #define TARGET_K 351
331 #define TRUNCATE 352
332 #define VERSIONK 353
333 #define OPTION 354
334 #define PARSING_LINKER_SCRIPT 355
335 #define PARSING_VERSION_SCRIPT 356
336 #define PARSING_DEFSYM 357
337 #define PARSING_DYNAMIC_LIST 358
338 #define PARSING_SECTIONS_BLOCK 359
339 #define PARSING_SECTION_COMMANDS 360
340 #define PARSING_MEMORY_DEF 361
341
342 /* Value type. */
343 #if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED
344 union YYSTYPE
345 {
346 #line 53 "yyscript.y"
347
348 /* A string. */
349 struct Parser_string string;
350 /* A number. */
351 uint64_t integer;
352 /* An expression. */
353 Expression_ptr expr;
354 /* An output section header. */
355 struct Parser_output_section_header output_section_header;
356 /* An output section trailer. */
357 struct Parser_output_section_trailer output_section_trailer;
358 /* A section constraint. */
359 enum Section_constraint constraint;
360 /* A complete input section specification. */
361 struct Input_section_spec input_section_spec;
362 /* A list of wildcard specifications, with exclusions. */
363 struct Wildcard_sections wildcard_sections;
364 /* A single wildcard specification. */
365 struct Wildcard_section wildcard_section;
366 /* A list of strings. */
367 String_list_ptr string_list;
368 /* Information for a program header. */
369 struct Phdr_info phdr_info;
370 /* Used for version scripts and within VERSION {}. */
371 struct Version_dependency_list* deplist;
372 struct Version_expression_list* versyms;
373 struct Version_tree* versnode;
374 enum Script_section_type section_type;
375
376 #line 377 "yyscript.c"
377
378 };
379 typedef union YYSTYPE YYSTYPE;
380 # define YYSTYPE_IS_TRIVIAL 1
381 # define YYSTYPE_IS_DECLARED 1
382 #endif
383
384
385
386 int yyparse (void* closure);
387
388 #endif /* !YY_YY_YYSCRIPT_H_INCLUDED */
389
390
391
392 #ifdef short
393 # undef short
394 #endif
395
396 /* On compilers that do not define __PTRDIFF_MAX__ etc., make sure
397 <limits.h> and (if available) <stdint.h> are included
398 so that the code can choose integer types of a good width. */
399
400 #ifndef __PTRDIFF_MAX__
401 # include <limits.h> /* INFRINGES ON USER NAME SPACE */
402 # if defined __STDC_VERSION__ && 199901 <= __STDC_VERSION__
403 # include <stdint.h> /* INFRINGES ON USER NAME SPACE */
404 # define YY_STDINT_H
405 # endif
406 #endif
407
408 /* Narrow types that promote to a signed type and that can represent a
409 signed or unsigned integer of at least N bits. In tables they can
410 save space and decrease cache pressure. Promoting to a signed type
411 helps avoid bugs in integer arithmetic. */
412
413 #ifdef __INT_LEAST8_MAX__
414 typedef __INT_LEAST8_TYPE__ yytype_int8;
415 #elif defined YY_STDINT_H
416 typedef int_least8_t yytype_int8;
417 #else
418 typedef signed char yytype_int8;
419 #endif
420
421 #ifdef __INT_LEAST16_MAX__
422 typedef __INT_LEAST16_TYPE__ yytype_int16;
423 #elif defined YY_STDINT_H
424 typedef int_least16_t yytype_int16;
425 #else
426 typedef short yytype_int16;
427 #endif
428
429 #if defined __UINT_LEAST8_MAX__ && __UINT_LEAST8_MAX__ <= __INT_MAX__
430 typedef __UINT_LEAST8_TYPE__ yytype_uint8;
431 #elif (!defined __UINT_LEAST8_MAX__ && defined YY_STDINT_H \
432 && UINT_LEAST8_MAX <= INT_MAX)
433 typedef uint_least8_t yytype_uint8;
434 #elif !defined __UINT_LEAST8_MAX__ && UCHAR_MAX <= INT_MAX
435 typedef unsigned char yytype_uint8;
436 #else
437 typedef short yytype_uint8;
438 #endif
439
440 #if defined __UINT_LEAST16_MAX__ && __UINT_LEAST16_MAX__ <= __INT_MAX__
441 typedef __UINT_LEAST16_TYPE__ yytype_uint16;
442 #elif (!defined __UINT_LEAST16_MAX__ && defined YY_STDINT_H \
443 && UINT_LEAST16_MAX <= INT_MAX)
444 typedef uint_least16_t yytype_uint16;
445 #elif !defined __UINT_LEAST16_MAX__ && USHRT_MAX <= INT_MAX
446 typedef unsigned short yytype_uint16;
447 #else
448 typedef int yytype_uint16;
449 #endif
450
451 #ifndef YYPTRDIFF_T
452 # if defined __PTRDIFF_TYPE__ && defined __PTRDIFF_MAX__
453 # define YYPTRDIFF_T __PTRDIFF_TYPE__
454 # define YYPTRDIFF_MAXIMUM __PTRDIFF_MAX__
455 # elif defined PTRDIFF_MAX
456 # ifndef ptrdiff_t
457 # include <stddef.h> /* INFRINGES ON USER NAME SPACE */
458 # endif
459 # define YYPTRDIFF_T ptrdiff_t
460 # define YYPTRDIFF_MAXIMUM PTRDIFF_MAX
461 # else
462 # define YYPTRDIFF_T long
463 # define YYPTRDIFF_MAXIMUM LONG_MAX
464 # endif
465 #endif
466
467 #ifndef YYSIZE_T
468 # ifdef __SIZE_TYPE__
469 # define YYSIZE_T __SIZE_TYPE__
470 # elif defined size_t
471 # define YYSIZE_T size_t
472 # elif defined __STDC_VERSION__ && 199901 <= __STDC_VERSION__
473 # include <stddef.h> /* INFRINGES ON USER NAME SPACE */
474 # define YYSIZE_T size_t
475 # else
476 # define YYSIZE_T unsigned
477 # endif
478 #endif
479
480 #define YYSIZE_MAXIMUM \
481 YY_CAST (YYPTRDIFF_T, \
482 (YYPTRDIFF_MAXIMUM < YY_CAST (YYSIZE_T, -1) \
483 ? YYPTRDIFF_MAXIMUM \
484 : YY_CAST (YYSIZE_T, -1)))
485
486 #define YYSIZEOF(X) YY_CAST (YYPTRDIFF_T, sizeof (X))
487
488 /* Stored state numbers (used for stacks). */
489 typedef yytype_int16 yy_state_t;
490
491 /* State numbers in computations. */
492 typedef int yy_state_fast_t;
493
494 #ifndef YY_
495 # if defined YYENABLE_NLS && YYENABLE_NLS
496 # if ENABLE_NLS
497 # include <libintl.h> /* INFRINGES ON USER NAME SPACE */
498 # define YY_(Msgid) dgettext ("bison-runtime", Msgid)
499 # endif
500 # endif
501 # ifndef YY_
502 # define YY_(Msgid) Msgid
503 # endif
504 #endif
505
506 #ifndef YY_ATTRIBUTE_PURE
507 # if defined __GNUC__ && 2 < __GNUC__ + (96 <= __GNUC_MINOR__)
508 # define YY_ATTRIBUTE_PURE __attribute__ ((__pure__))
509 # else
510 # define YY_ATTRIBUTE_PURE
511 # endif
512 #endif
513
514 #ifndef YY_ATTRIBUTE_UNUSED
515 # if defined __GNUC__ && 2 < __GNUC__ + (7 <= __GNUC_MINOR__)
516 # define YY_ATTRIBUTE_UNUSED __attribute__ ((__unused__))
517 # else
518 # define YY_ATTRIBUTE_UNUSED
519 # endif
520 #endif
521
522 /* Suppress unused-variable warnings by "using" E. */
523 #if ! defined lint || defined __GNUC__
524 # define YYUSE(E) ((void) (E))
525 #else
526 # define YYUSE(E) /* empty */
527 #endif
528
529 #if defined __GNUC__ && ! defined __ICC && 407 <= __GNUC__ * 100 + __GNUC_MINOR__
530 /* Suppress an incorrect diagnostic about yylval being uninitialized. */
531 # define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN \
532 _Pragma ("GCC diagnostic push") \
533 _Pragma ("GCC diagnostic ignored \"-Wuninitialized\"") \
534 _Pragma ("GCC diagnostic ignored \"-Wmaybe-uninitialized\"")
535 # define YY_IGNORE_MAYBE_UNINITIALIZED_END \
536 _Pragma ("GCC diagnostic pop")
537 #else
538 # define YY_INITIAL_VALUE(Value) Value
539 #endif
540 #ifndef YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
541 # define YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
542 # define YY_IGNORE_MAYBE_UNINITIALIZED_END
543 #endif
544 #ifndef YY_INITIAL_VALUE
545 # define YY_INITIAL_VALUE(Value) /* Nothing. */
546 #endif
547
548 #if defined __cplusplus && defined __GNUC__ && ! defined __ICC && 6 <= __GNUC__
549 # define YY_IGNORE_USELESS_CAST_BEGIN \
550 _Pragma ("GCC diagnostic push") \
551 _Pragma ("GCC diagnostic ignored \"-Wuseless-cast\"")
552 # define YY_IGNORE_USELESS_CAST_END \
553 _Pragma ("GCC diagnostic pop")
554 #endif
555 #ifndef YY_IGNORE_USELESS_CAST_BEGIN
556 # define YY_IGNORE_USELESS_CAST_BEGIN
557 # define YY_IGNORE_USELESS_CAST_END
558 #endif
559
560
561 #define YY_ASSERT(E) ((void) (0 && (E)))
562
563 #if ! defined yyoverflow || YYERROR_VERBOSE
564
565 /* The parser invokes alloca or malloc; define the necessary symbols. */
566
567 # ifdef YYSTACK_USE_ALLOCA
568 # if YYSTACK_USE_ALLOCA
569 # ifdef __GNUC__
570 # define YYSTACK_ALLOC __builtin_alloca
571 # elif defined __BUILTIN_VA_ARG_INCR
572 # include <alloca.h> /* INFRINGES ON USER NAME SPACE */
573 # elif defined _AIX
574 # define YYSTACK_ALLOC __alloca
575 # elif defined _MSC_VER
576 # include <malloc.h> /* INFRINGES ON USER NAME SPACE */
577 # define alloca _alloca
578 # else
579 # define YYSTACK_ALLOC alloca
580 # if ! defined _ALLOCA_H && ! defined EXIT_SUCCESS
581 # include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
582 /* Use EXIT_SUCCESS as a witness for stdlib.h. */
583 # ifndef EXIT_SUCCESS
584 # define EXIT_SUCCESS 0
585 # endif
586 # endif
587 # endif
588 # endif
589 # endif
590
591 # ifdef YYSTACK_ALLOC
592 /* Pacify GCC's 'empty if-body' warning. */
593 # define YYSTACK_FREE(Ptr) do { /* empty */; } while (0)
594 # ifndef YYSTACK_ALLOC_MAXIMUM
595 /* The OS might guarantee only one guard page at the bottom of the stack,
596 and a page size can be as small as 4096 bytes. So we cannot safely
597 invoke alloca (N) if N exceeds 4096. Use a slightly smaller number
598 to allow for a few compiler-allocated temporary stack slots. */
599 # define YYSTACK_ALLOC_MAXIMUM 4032 /* reasonable circa 2006 */
600 # endif
601 # else
602 # define YYSTACK_ALLOC YYMALLOC
603 # define YYSTACK_FREE YYFREE
604 # ifndef YYSTACK_ALLOC_MAXIMUM
605 # define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM
606 # endif
607 # if (defined __cplusplus && ! defined EXIT_SUCCESS \
608 && ! ((defined YYMALLOC || defined malloc) \
609 && (defined YYFREE || defined free)))
610 # include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
611 # ifndef EXIT_SUCCESS
612 # define EXIT_SUCCESS 0
613 # endif
614 # endif
615 # ifndef YYMALLOC
616 # define YYMALLOC malloc
617 # if ! defined malloc && ! defined EXIT_SUCCESS
618 void *malloc (YYSIZE_T); /* INFRINGES ON USER NAME SPACE */
619 # endif
620 # endif
621 # ifndef YYFREE
622 # define YYFREE free
623 # if ! defined free && ! defined EXIT_SUCCESS
624 void free (void *); /* INFRINGES ON USER NAME SPACE */
625 # endif
626 # endif
627 # endif
628 #endif /* ! defined yyoverflow || YYERROR_VERBOSE */
629
630
631 #if (! defined yyoverflow \
632 && (! defined __cplusplus \
633 || (defined YYSTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL)))
634
635 /* A type that is properly aligned for any stack member. */
636 union yyalloc
637 {
638 yy_state_t yyss_alloc;
639 YYSTYPE yyvs_alloc;
640 };
641
642 /* The size of the maximum gap between one aligned stack and the next. */
643 # define YYSTACK_GAP_MAXIMUM (YYSIZEOF (union yyalloc) - 1)
644
645 /* The size of an array large to enough to hold all stacks, each with
646 N elements. */
647 # define YYSTACK_BYTES(N) \
648 ((N) * (YYSIZEOF (yy_state_t) + YYSIZEOF (YYSTYPE)) \
649 + YYSTACK_GAP_MAXIMUM)
650
651 # define YYCOPY_NEEDED 1
652
653 /* Relocate STACK from its old location to the new one. The
654 local variables YYSIZE and YYSTACKSIZE give the old and new number of
655 elements in the stack, and YYPTR gives the new location of the
656 stack. Advance YYPTR to a properly aligned location for the next
657 stack. */
658 # define YYSTACK_RELOCATE(Stack_alloc, Stack) \
659 do \
660 { \
661 YYPTRDIFF_T yynewbytes; \
662 YYCOPY (&yyptr->Stack_alloc, Stack, yysize); \
663 Stack = &yyptr->Stack_alloc; \
664 yynewbytes = yystacksize * YYSIZEOF (*Stack) + YYSTACK_GAP_MAXIMUM; \
665 yyptr += yynewbytes / YYSIZEOF (*yyptr); \
666 } \
667 while (0)
668
669 #endif
670
671 #if defined YYCOPY_NEEDED && YYCOPY_NEEDED
672 /* Copy COUNT objects from SRC to DST. The source and destination do
673 not overlap. */
674 # ifndef YYCOPY
675 # if defined __GNUC__ && 1 < __GNUC__
676 # define YYCOPY(Dst, Src, Count) \
677 __builtin_memcpy (Dst, Src, YY_CAST (YYSIZE_T, (Count)) * sizeof (*(Src)))
678 # else
679 # define YYCOPY(Dst, Src, Count) \
680 do \
681 { \
682 YYPTRDIFF_T yyi; \
683 for (yyi = 0; yyi < (Count); yyi++) \
684 (Dst)[yyi] = (Src)[yyi]; \
685 } \
686 while (0)
687 # endif
688 # endif
689 #endif /* !YYCOPY_NEEDED */
690
691 /* YYFINAL -- State number of the termination state. */
692 #define YYFINAL 26
693 /* YYLAST -- Last index in YYTABLE. */
694 #define YYLAST 1465
695
696 /* YYNTOKENS -- Number of terminals. */
697 #define YYNTOKENS 130
698 /* YYNNTS -- Number of nonterminals. */
699 #define YYNNTS 70
700 /* YYNRULES -- Number of rules. */
701 #define YYNRULES 241
702 /* YYNSTATES -- Number of states. */
703 #define YYNSTATES 555
704
705 #define YYUNDEFTOK 2
706 #define YYMAXUTOK 361
707
708
709 /* YYTRANSLATE(TOKEN-NUM) -- Symbol number corresponding to TOKEN-NUM
710 as returned by yylex, with out-of-bounds checking. */
711 #define YYTRANSLATE(YYX) \
712 (0 <= (YYX) && (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK)
713
714 /* YYTRANSLATE[TOKEN-NUM] -- Symbol number corresponding to TOKEN-NUM
715 as returned by yylex. */
716 static const yytype_uint8 yytranslate[] =
717 {
718 0, 2, 2, 2, 2, 2, 2, 2, 2, 2,
719 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
720 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
721 2, 2, 2, 126, 2, 2, 2, 31, 18, 2,
722 120, 121, 29, 27, 124, 28, 2, 30, 2, 2,
723 2, 2, 2, 2, 2, 2, 2, 2, 13, 125,
724 21, 7, 22, 12, 2, 2, 2, 2, 2, 2,
725 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
726 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
727 2, 2, 2, 2, 17, 2, 2, 2, 2, 2,
728 2, 2, 2, 2, 2, 2, 2, 2, 128, 2,
729 2, 127, 2, 2, 2, 2, 2, 2, 2, 2,
730 2, 2, 2, 122, 16, 123, 129, 2, 2, 2,
731 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
732 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
733 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
734 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
735 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
736 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
737 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
738 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
739 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
740 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
741 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
742 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
743 2, 2, 2, 2, 2, 2, 1, 2, 3, 4,
744 5, 6, 8, 9, 10, 11, 14, 15, 19, 20,
745 23, 24, 25, 26, 32, 33, 34, 35, 36, 37,
746 38, 39, 40, 41, 42, 43, 44, 45, 46, 47,
747 48, 49, 50, 51, 52, 53, 54, 55, 56, 57,
748 58, 59, 60, 61, 62, 63, 64, 65, 66, 67,
749 68, 69, 70, 71, 72, 73, 74, 75, 76, 77,
750 78, 79, 80, 81, 82, 83, 84, 85, 86, 87,
751 88, 89, 90, 91, 92, 93, 94, 95, 96, 97,
752 98, 99, 100, 101, 102, 103, 104, 105, 106, 107,
753 108, 109, 110, 111, 112, 113, 114, 115, 116, 117,
754 118, 119
755 };
756
757 #if YYDEBUG
758 /* YYRLINE[YYN] -- Source line where rule number YYN was defined. */
759 static const yytype_int16 yyrline[] =
760 {
761 0, 236, 236, 237, 238, 239, 240, 241, 242, 247,
762 248, 253, 254, 257, 256, 260, 262, 263, 264, 266,
763 272, 279, 280, 283, 282, 286, 289, 288, 292, 294,
764 295, 297, 300, 301, 309, 317, 317, 323, 325, 327,
765 333, 334, 339, 341, 344, 343, 351, 352, 357, 359,
766 360, 362, 366, 365, 374, 376, 374, 393, 398, 403,
767 408, 413, 418, 427, 429, 434, 439, 444, 454, 455,
768 462, 463, 470, 471, 478, 479, 481, 483, 489, 498,
769 500, 505, 507, 512, 515, 521, 524, 529, 531, 537,
770 538, 539, 541, 543, 545, 552, 553, 556, 562, 564,
771 566, 568, 570, 577, 579, 585, 592, 601, 606, 615,
772 620, 625, 630, 639, 644, 663, 682, 691, 693, 700,
773 702, 707, 716, 717, 722, 725, 728, 733, 736, 739,
774 743, 745, 747, 751, 753, 755, 760, 761, 766, 775,
775 777, 784, 785, 793, 798, 809, 818, 820, 826, 832,
776 838, 844, 850, 856, 862, 868, 870, 872, 878, 878,
777 888, 890, 892, 894, 896, 898, 900, 902, 904, 906,
778 908, 910, 912, 914, 916, 918, 920, 922, 924, 926,
779 928, 930, 932, 934, 936, 938, 940, 942, 944, 946,
780 948, 950, 952, 954, 956, 958, 960, 962, 964, 966,
781 968, 970, 975, 980, 982, 990, 996, 1006, 1009, 1010,
782 1014, 1020, 1024, 1025, 1029, 1033, 1038, 1045, 1049, 1057,
783 1058, 1060, 1062, 1064, 1073, 1078, 1083, 1088, 1095, 1094,
784 1105, 1104, 1111, 1116, 1126, 1128, 1135, 1136, 1141, 1142,
785 1147, 1148
786 };
787 #endif
788
789 #if YYDEBUG || YYERROR_VERBOSE || 1
790 /* YYTNAME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM.
791 First, the terminals, then, starting at YYNTOKENS, nonterminals. */
792 static const char *const yytname[] =
793 {
794 "$end", "error", "$undefined", "PLUSEQ", "MINUSEQ", "MULTEQ", "DIVEQ",
795 "'='", "LSHIFTEQ", "RSHIFTEQ", "ANDEQ", "OREQ", "'?'", "':'", "OROR",
796 "ANDAND", "'|'", "'^'", "'&'", "EQ", "NE", "'<'", "'>'", "LE", "GE",
797 "LSHIFT", "RSHIFT", "'+'", "'-'", "'*'", "'/'", "'%'", "UNARY", "STRING",
798 "QUOTED_STRING", "INTEGER", "ABSOLUTE", "ADDR", "ALIGN_K", "ALIGNOF",
799 "ASSERT_K", "AS_NEEDED", "AT", "BIND", "BLOCK", "BYTE", "CONSTANT",
800 "CONSTRUCTORS", "COPY", "CREATE_OBJECT_SYMBOLS", "DATA_SEGMENT_ALIGN",
801 "DATA_SEGMENT_END", "DATA_SEGMENT_RELRO_END", "DEFINED", "DSECT",
802 "ENTRY", "EXCLUDE_FILE", "EXTERN", "FILL", "FLOAT",
803 "FORCE_COMMON_ALLOCATION", "GLOBAL", "GROUP", "HIDDEN", "HLL", "INCLUDE",
804 "INHIBIT_COMMON_ALLOCATION", "INFO", "INPUT", "KEEP", "LEN", "LENGTH",
805 "LOADADDR", "LOCAL", "LONG", "MAP", "MAX_K", "MEMORY", "MIN_K", "NEXT",
806 "NOCROSSREFS", "NOFLOAT", "NOLOAD", "ONLY_IF_RO", "ONLY_IF_RW", "ORG",
807 "ORIGIN", "OUTPUT", "OUTPUT_ARCH", "OUTPUT_FORMAT", "OVERLAY", "PHDRS",
808 "PROVIDE", "PROVIDE_HIDDEN", "QUAD", "SEARCH_DIR", "SECTIONS",
809 "SEGMENT_START", "SHORT", "SIZEOF", "SIZEOF_HEADERS",
810 "SORT_BY_ALIGNMENT", "SORT_BY_INIT_PRIORITY", "SORT_BY_NAME", "SPECIAL",
811 "SQUAD", "STARTUP", "SUBALIGN", "SYSLIB", "TARGET_K", "TRUNCATE",
812 "VERSIONK", "OPTION", "PARSING_LINKER_SCRIPT", "PARSING_VERSION_SCRIPT",
813 "PARSING_DEFSYM", "PARSING_DYNAMIC_LIST", "PARSING_SECTIONS_BLOCK",
814 "PARSING_SECTION_COMMANDS", "PARSING_MEMORY_DEF", "'('", "')'", "'{'",
815 "'}'", "','", "';'", "'!'", "'o'", "'l'", "'~'", "$accept", "top",
816 "linker_script", "file_cmd", "$@1", "$@2", "$@3", "ignore_cmd",
817 "extern_name_list", "$@4", "extern_name_list_body", "input_list",
818 "input_list_element", "$@5", "sections_block", "section_block_cmd",
819 "$@6", "section_header", "$@7", "$@8", "opt_address_and_section_type",
820 "section_type", "opt_at", "opt_align", "opt_subalign", "opt_constraint",
821 "section_trailer", "opt_memspec", "opt_at_memspec", "opt_phdr",
822 "opt_fill", "section_cmds", "section_cmd", "data_length",
823 "input_section_spec", "input_section_no_keep", "wildcard_file",
824 "wildcard_sections", "wildcard_section", "exclude_names",
825 "wildcard_name", "memory_defs", "memory_def", "memory_attr",
826 "memory_origin", "memory_length", "phdrs_defs", "phdr_def", "phdr_type",
827 "phdr_info", "assignment", "parse_exp", "$@9", "exp", "defsym_expr",
828 "dynamic_list_expr", "dynamic_list_nodes", "dynamic_list_node",
829 "version_script", "vers_nodes", "vers_node", "verdep", "vers_tag",
830 "vers_defns", "$@10", "$@11", "string", "end", "opt_semicolon",
831 "opt_comma", YY_NULLPTR
832 };
833 #endif
834
835 # ifdef YYPRINT
836 /* YYTOKNUM[NUM] -- (External) token number corresponding to the
837 (internal) symbol number NUM (which must be that of a token). */
838 static const yytype_int16 yytoknum[] =
839 {
840 0, 256, 257, 258, 259, 260, 261, 61, 262, 263,
841 264, 265, 63, 58, 266, 267, 124, 94, 38, 268,
842 269, 60, 62, 270, 271, 272, 273, 43, 45, 42,
843 47, 37, 274, 275, 276, 277, 278, 279, 280, 281,
844 282, 283, 284, 285, 286, 287, 288, 289, 290, 291,
845 292, 293, 294, 295, 296, 297, 298, 299, 300, 301,
846 302, 303, 304, 305, 306, 307, 308, 309, 310, 311,
847 312, 313, 314, 315, 316, 317, 318, 319, 320, 321,
848 322, 323, 324, 325, 326, 327, 328, 329, 330, 331,
849 332, 333, 334, 335, 336, 337, 338, 339, 340, 341,
850 342, 343, 344, 345, 346, 347, 348, 349, 350, 351,
851 352, 353, 354, 355, 356, 357, 358, 359, 360, 361,
852 40, 41, 123, 125, 44, 59, 33, 111, 108, 126
853 };
854 # endif
855
856 #define YYPACT_NINF (-423)
857
858 #define yypact_value_is_default(Yyn) \
859 ((Yyn) == YYPACT_NINF)
860
861 #define YYTABLE_NINF (-120)
862
863 #define yytable_value_is_error(Yyn) \
864 0
865
866 /* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing
867 STATE-NUM. */
868 static const yytype_int16 yypact[] =
869 {
870 365, -423, 81, 214, -112, -423, -423, -423, 14, 1300,
871 -423, -423, 33, -423, 81, -423, -93, -423, 52, 103,
872 -423, -112, -423, 177, 568, 9, -423, -37, -28, -1,
873 -423, -423, 15, 214, -423, 19, -69, 60, 62, 1,
874 64, 80, 82, 73, 84, 90, 86, -423, -423, -423,
875 136, 318, -423, -423, 214, 208, 217, 104, 108, -423,
876 33, -423, 113, -423, 132, 155, 214, -423, 136, 318,
877 -423, -423, 157, -423, -423, 160, 214, 162, -423, -423,
878 -423, 168, -423, -423, -423, 169, -423, -423, 174, -423,
879 136, 38, -423, 92, -423, 214, -423, 195, 214, -423,
880 231, -423, 214, 214, -423, 214, 214, 214, -423, 214,
881 -423, 214, -423, -423, -423, -423, -423, -423, -423, -423,
882 -423, -423, -423, -423, 151, 103, 103, 192, 159, 156,
883 -423, 1253, 21, -423, 214, -423, -423, -423, 137, -423,
884 -423, -423, 39, 422, -423, 46, -423, 214, -423, 199,
885 207, 215, 220, 214, 231, 341, 316, -423, -40, -423,
886 -423, 144, 229, 3, 36, 345, 346, 264, -423, 266,
887 81, 267, -423, -423, -423, -423, -423, -423, -423, -423,
888 -423, -423, 269, 270, -423, -423, -423, 214, -17, 1253,
889 1253, -423, 271, 272, 276, 279, 280, 305, 306, 309,
890 310, 312, 322, 323, 324, 330, 332, 333, 337, 339,
891 -423, 1253, 1253, 1253, 1434, -423, 335, 265, 340, 343,
892 -423, 1156, 420, 1151, 350, 349, 355, 364, 356, 374,
893 375, -423, 376, 397, 398, 399, 400, 7, -423, -423,
894 -423, -10, 508, 214, -423, -423, -6, -423, 70, -423,
895 -423, 402, -423, 231, -423, -423, -423, 214, -423, -423,
896 300, -423, -423, -423, 191, -423, 401, -423, 103, 96,
897 159, 403, -423, -8, -423, -423, -423, 1253, 214, 1253,
898 214, 1253, 1253, 214, 1253, 1253, 1253, 214, 214, 214,
899 1253, 1253, 214, 214, 214, 281, -423, -423, 1253, 1253,
900 1253, 1253, 1253, 1253, 1253, 1253, 1253, 1253, 1253, 1253,
901 1253, 1253, 1253, 1253, 1253, 1253, 1253, -423, 214, -423,
902 -423, -423, -423, -423, -423, -423, 510, 406, 408, 491,
903 -423, 153, 214, -423, 216, -423, -423, -423, -423, 216,
904 53, 216, 53, -423, 412, 214, 410, -67, 413, 214,
905 -423, -423, 416, 231, -423, 415, -423, 29, -423, 421,
906 426, -423, -423, 405, 535, -423, -423, -423, 825, 430,
907 342, 431, 392, 862, 432, 714, 882, 751, 433, 434,
908 435, 771, 791, 455, 454, 458, -423, 1414, 731, 841,
909 948, 481, 562, 353, 353, 463, 463, 463, 463, 409,
910 409, 315, 315, -423, -423, -423, 474, 565, -423, 583,
911 1253, 480, 496, 591, 485, 486, 75, -423, 488, 490,
912 493, 497, -423, 495, -423, -423, -423, -423, 611, -423,
913 -423, -423, 98, 214, 499, 29, 500, 43, -423, -423,
914 159, 498, 103, 103, -423, -423, -423, 1253, -423, 214,
915 -423, -423, 1253, -423, 1253, -423, -423, -423, 1253, 1253,
916 -423, 1253, -423, 1253, -423, 598, -423, 902, 1253, 502,
917 -423, -423, 614, -423, -423, 216, -423, -423, -423, 216,
918 -423, -423, -423, 503, -423, -423, -423, 594, -423, -423,
919 507, 405, 933, 514, 970, 990, 1010, 1041, 1078, 1434,
920 214, -423, 596, -423, 1098, 1253, 114, -423, -423, 105,
921 512, -423, 519, 520, 159, 521, -423, -423, -423, -423,
922 -423, -423, -423, -423, 621, -423, -423, 1118, -423, -423,
923 -423, -423, -423, 18, 29, 29, -423, 214, 154, -423,
924 -423, -423, -423, 638, -423, -423, -423, -423, 214, 512,
925 -423, -423, -423, -423, -423
926 };
927
928 /* YYDEFACT[STATE-NUM] -- Default reduction number in state STATE-NUM.
929 Performed when YYTABLE does not specify something else to do. Zero
930 means the default is an error. */
931 static const yytype_uint8 yydefact[] =
932 {
933 0, 10, 0, 0, 0, 47, 87, 123, 0, 2,
934 234, 235, 219, 3, 211, 212, 0, 4, 0, 0,
935 5, 207, 208, 6, 7, 241, 1, 0, 0, 0,
936 12, 13, 0, 0, 15, 0, 0, 0, 0, 0,
937 0, 0, 0, 0, 0, 0, 0, 33, 9, 32,
938 0, 0, 224, 225, 232, 0, 0, 0, 0, 213,
939 219, 158, 0, 209, 0, 0, 0, 46, 0, 54,
940 121, 120, 0, 102, 94, 0, 0, 0, 100, 98,
941 101, 0, 99, 97, 88, 0, 90, 103, 0, 107,
942 0, 105, 240, 126, 158, 0, 35, 0, 0, 31,
943 0, 123, 0, 0, 137, 0, 0, 0, 23, 0,
944 26, 0, 237, 236, 29, 158, 158, 158, 158, 158,
945 158, 158, 158, 158, 0, 0, 0, 0, 220, 0,
946 206, 0, 0, 158, 0, 51, 49, 52, 0, 158,
947 158, 96, 0, 0, 158, 0, 89, 0, 122, 129,
948 0, 0, 0, 0, 0, 0, 0, 44, 241, 40,
949 42, 241, 0, 0, 0, 0, 0, 0, 47, 0,
950 0, 0, 147, 148, 149, 150, 146, 151, 152, 153,
951 154, 228, 0, 0, 214, 226, 227, 233, 0, 0,
952 0, 184, 0, 0, 0, 0, 0, 0, 0, 0,
953 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
954 189, 0, 0, 0, 159, 185, 0, 0, 0, 0,
955 57, 0, 68, 0, 0, 0, 0, 0, 105, 0,
956 0, 119, 0, 0, 0, 0, 0, 241, 110, 113,
957 125, 0, 0, 0, 28, 11, 36, 37, 241, 158,
958 43, 0, 16, 0, 17, 34, 19, 0, 21, 136,
959 0, 158, 158, 22, 0, 25, 0, 18, 0, 221,
960 222, 0, 215, 0, 217, 164, 161, 0, 0, 0,
961 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
962 0, 0, 0, 0, 0, 0, 162, 163, 0, 0,
963 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
964 0, 0, 0, 0, 0, 0, 0, 210, 0, 48,
965 87, 65, 64, 66, 63, 67, 0, 0, 0, 70,
966 59, 0, 0, 93, 0, 104, 95, 108, 91, 0,
967 0, 0, 0, 106, 0, 0, 0, 0, 0, 0,
968 38, 14, 0, 0, 41, 0, 140, 141, 139, 0,
969 0, 24, 27, 239, 0, 230, 216, 218, 0, 0,
970 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
971 0, 0, 0, 0, 0, 0, 160, 0, 182, 181,
972 180, 179, 178, 172, 173, 176, 177, 174, 175, 170,
973 171, 168, 169, 165, 166, 167, 0, 0, 58, 0,
974 0, 0, 72, 0, 0, 0, 241, 118, 0, 0,
975 0, 0, 109, 0, 127, 131, 130, 132, 0, 30,
976 39, 155, 241, 0, 0, 141, 0, 141, 156, 157,
977 238, 0, 0, 0, 197, 192, 198, 0, 190, 0,
978 200, 196, 0, 203, 0, 188, 195, 193, 0, 0,
979 194, 0, 191, 0, 50, 80, 61, 0, 0, 0,
980 55, 60, 0, 92, 112, 0, 115, 116, 114, 0,
981 128, 158, 45, 0, 158, 143, 138, 0, 142, 229,
982 0, 239, 0, 0, 0, 0, 0, 0, 0, 183,
983 0, 53, 82, 69, 0, 0, 74, 62, 117, 241,
984 241, 20, 0, 0, 223, 0, 199, 205, 201, 202,
985 186, 187, 204, 79, 0, 84, 71, 0, 75, 76,
986 77, 56, 111, 0, 141, 141, 231, 0, 86, 73,
987 134, 133, 135, 0, 145, 144, 81, 158, 0, 241,
988 158, 85, 83, 78, 124
989 };
990
991 /* YYPGOTO[NTERM-NUM]. */
992 static const yytype_int16 yypgoto[] =
993 {
994 -423, -423, -423, -423, -423, -423, -423, -423, -423, -423,
995 -423, -148, 393, -423, 479, -423, -423, -423, -423, -423,
996 -423, 317, -423, -423, -423, -423, -423, -423, -423, -423,
997 -423, 329, -423, -423, -423, 509, -423, -423, -245, 171,
998 -21, 551, -423, -423, -423, -423, -423, -423, -423, -422,
999 -4, -83, -423, 259, -423, -423, -423, 632, 484, -423,
1000 641, -423, 604, -15, -423, -423, -2, -60, 165, -23
1001 };
1002
1003 /* YYDEFGOTO[NTERM-NUM]. */
1004 static const yytype_int16 yydefgoto[] =
1005 {
1006 -1, 8, 9, 48, 97, 168, 170, 49, 152, 153,
1007 246, 158, 159, 251, 23, 67, 219, 137, 138, 506,
1008 222, 327, 329, 412, 470, 531, 501, 502, 525, 538,
1009 549, 24, 84, 85, 86, 87, 88, 237, 238, 416,
1010 239, 25, 148, 242, 428, 543, 164, 259, 357, 436,
1011 68, 130, 131, 295, 17, 20, 21, 22, 13, 14,
1012 15, 273, 57, 58, 268, 443, 215, 114, 441, 253
1013 };
1014
1015 /* YYTABLE[YYPACT[STATE-NUM]] -- What to do in state STATE-NUM. If
1016 positive, shift that token. If negative, reduce the rule whose
1017 number is the opposite. If YYTABLE_NINF, syntax error. */
1018 static const yytype_int16 yytable[] =
1019 {
1020 16, 18, 93, 89, 62, 50, 248, 51, 136, -8,
1021 19, 150, 16, 485, 26, 488, 10, 11, 425, 426,
1022 90, 69, 91, 10, 11, 10, 11, 10, 11, 60,
1023 146, 99, 172, 173, 174, 175, 176, 177, 178, 179,
1024 180, 115, 116, 117, 118, 119, 120, 121, 122, 123,
1025 217, 70, 124, 101, 185, 186, 224, 225, 70, 61,
1026 427, 232, 10, 11, 135, 70, 52, 53, 71, 10,
1027 11, 434, 10, 11, 141, 71, 10, 11, 187, 10,
1028 11, 252, 71, 94, 92, 434, 10, 11, 540, 541,
1029 54, 149, 95, 151, 55, 418, 155, 420, 160, 422,
1030 162, 163, 233, 165, 166, 167, 56, 169, 272, 171,
1031 182, 183, 544, 545, 10, 11, 345, 366, 349, 96,
1032 435, 89, 230, 104, 256, 10, 11, 257, 343, 185,
1033 186, 92, 218, 92, 435, 98, 52, 53, 93, 100,
1034 228, 231, 226, 231, 216, 240, 542, 234, 235, 236,
1035 220, 247, 160, 187, 234, 235, 236, 147, -119, 258,
1036 54, 547, 260, 487, 189, 190, 352, 548, 16, 364,
1037 10, 11, 191, 192, 193, 194, 195, 196, 359, 360,
1038 102, 197, 103, 198, 105, 271, 274, 199, 200, 201,
1039 202, 351, 185, 186, 92, 108, 474, 528, 529, 92,
1040 106, 321, 107, 12, 109, 432, 111, 322, 203, 204,
1041 10, 11, 110, 205, 344, 206, 187, 64, 530, 482,
1042 323, 125, 92, 207, 10, 11, 532, 127, 70, 92,
1043 126, 64, 65, 128, 208, 324, 209, 210, 132, 346,
1044 32, 348, 66, 325, 350, 71, 65, 10, 11, 10,
1045 11, 160, 133, 363, 32, 355, 66, 221, 358, 156,
1046 112, 113, 69, 212, 10, 11, 213, 254, 92, 40,
1047 41, 367, 157, 181, 413, 134, 369, 139, 371, 188,
1048 140, 374, 142, 40, 41, 378, 379, 380, 143, 144,
1049 383, 384, 385, 298, 145, 299, 300, 301, 302, 303,
1050 304, 305, 306, 307, 308, 309, 310, 311, 312, 313,
1051 314, 315, 316, 230, 361, 154, 406, 184, 417, 241,
1052 419, 115, 116, 117, 118, 119, 120, 121, 122, 123,
1053 415, 243, 231, 10, 11, 356, 244, 231, 231, 231,
1054 231, 245, 231, 423, 314, 315, 316, 430, 249, 250,
1055 255, 160, 261, 262, 298, 437, 299, 300, 301, 302,
1056 303, 304, 305, 306, 307, 308, 309, 310, 311, 312,
1057 313, 314, 315, 316, 306, 307, 308, 309, 310, 311,
1058 312, 313, 314, 315, 316, 263, 89, 265, 267, 318,
1059 214, 277, 278, 475, 269, 270, 279, 223, 510, 280,
1060 281, 512, 386, 90, 298, 91, 299, 300, 301, 302,
1061 303, 304, 305, 306, 307, 308, 309, 310, 311, 312,
1062 313, 314, 315, 316, 70, 282, 283, 490, 491, 284,
1063 285, 483, 286, 437, 70, 437, 312, 313, 314, 315,
1064 316, 71, 287, 288, 289, 10, 11, 493, 275, 276,
1065 290, 71, 291, 292, 508, 10, 11, 293, 417, 294,
1066 317, 319, 328, 446, 551, 320, 447, 554, 421, 229,
1067 333, 296, 297, 231, 332, 334, -119, 231, 1, 2,
1068 3, 4, 5, 6, 7, 335, 475, 533, 310, 311,
1069 312, 313, 314, 315, 316, 336, 337, 338, 523, 303,
1070 304, 305, 306, 307, 308, 309, 310, 311, 312, 313,
1071 314, 315, 316, 234, 235, 236, 449, 339, 340, 341,
1072 342, 347, 353, 408, 362, 365, 553, 409, 410, 411,
1073 440, 424, 437, 437, 429, 546, 368, 431, 370, 433,
1074 372, 373, 438, 375, 376, 377, 552, 439, 442, 381,
1075 382, 445, 448, 451, 455, 456, 457, 387, 388, 389,
1076 390, 391, 392, 393, 394, 395, 396, 397, 398, 399,
1077 400, 401, 402, 403, 404, 405, 460, 70, 461, 462,
1078 70, 304, 305, 306, 307, 308, 309, 310, 311, 312,
1079 313, 314, 315, 316, 71, 464, 466, 71, 10, 11,
1080 468, 10, 11, 469, 471, 72, 472, 473, 72, 476,
1081 73, 477, 74, 73, 478, 74, 480, 479, 481, 484,
1082 500, 489, 505, 75, 511, 486, 75, 507, 32, 513,
1083 76, 32, 514, 76, 77, 517, 92, 77, 524, 78,
1084 534, 535, 78, 537, 536, 550, 354, 264, 414, 407,
1085 509, 227, 161, 63, 266, 59, 515, 40, 41, 79,
1086 40, 41, 79, 80, 129, 0, 80, 0, 81, 467,
1087 82, 81, 0, 82, 0, 0, 0, 0, 0, 0,
1088 0, 0, 0, 0, 0, 0, 0, 0, 465, 0,
1089 83, 0, 0, 83, 0, 0, 0, 0, 0, 0,
1090 0, 0, 0, 0, 0, 0, 492, 0, 0, 0,
1091 0, 494, 0, 495, 0, 0, 0, 496, 497, 0,
1092 498, 0, 499, 0, 0, 0, 298, 504, 299, 300,
1093 301, 302, 303, 304, 305, 306, 307, 308, 309, 310,
1094 311, 312, 313, 314, 315, 316, 300, 301, 302, 303,
1095 304, 305, 306, 307, 308, 309, 310, 311, 312, 313,
1096 314, 315, 316, 298, 527, 299, 300, 301, 302, 303,
1097 304, 305, 306, 307, 308, 309, 310, 311, 312, 313,
1098 314, 315, 316, 298, 0, 299, 300, 301, 302, 303,
1099 304, 305, 306, 307, 308, 309, 310, 311, 312, 313,
1100 314, 315, 316, 298, 0, 299, 300, 301, 302, 303,
1101 304, 305, 306, 307, 308, 309, 310, 311, 312, 313,
1102 314, 315, 316, 0, 0, 0, 0, 0, 0, 0,
1103 0, 0, 0, 0, 0, 0, 0, 298, 452, 299,
1104 300, 301, 302, 303, 304, 305, 306, 307, 308, 309,
1105 310, 311, 312, 313, 314, 315, 316, 301, 302, 303,
1106 304, 305, 306, 307, 308, 309, 310, 311, 312, 313,
1107 314, 315, 316, 0, 298, 454, 299, 300, 301, 302,
1108 303, 304, 305, 306, 307, 308, 309, 310, 311, 312,
1109 313, 314, 315, 316, 298, 458, 299, 300, 301, 302,
1110 303, 304, 305, 306, 307, 308, 309, 310, 311, 312,
1111 313, 314, 315, 316, 298, 459, 299, 300, 301, 302,
1112 303, 304, 305, 306, 307, 308, 309, 310, 311, 312,
1113 313, 314, 315, 316, 0, 0, 0, 0, 0, 0,
1114 0, 0, 0, 0, 0, 298, 444, 299, 300, 301,
1115 302, 303, 304, 305, 306, 307, 308, 309, 310, 311,
1116 312, 313, 314, 315, 316, 302, 303, 304, 305, 306,
1117 307, 308, 309, 310, 311, 312, 313, 314, 315, 316,
1118 0, 0, 298, 450, 299, 300, 301, 302, 303, 304,
1119 305, 306, 307, 308, 309, 310, 311, 312, 313, 314,
1120 315, 316, 298, 453, 299, 300, 301, 302, 303, 304,
1121 305, 306, 307, 308, 309, 310, 311, 312, 313, 314,
1122 315, 316, 298, 503, 299, 300, 301, 302, 303, 304,
1123 305, 306, 307, 308, 309, 310, 311, 312, 313, 314,
1124 315, 316, 0, 0, 0, 0, 0, 0, 0, 0,
1125 0, 0, 0, 298, 516, 299, 300, 301, 302, 303,
1126 304, 305, 306, 307, 308, 309, 310, 311, 312, 313,
1127 314, 315, 316, 0, 0, 0, 0, 0, 0, 0,
1128 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
1129 298, 518, 299, 300, 301, 302, 303, 304, 305, 306,
1130 307, 308, 309, 310, 311, 312, 313, 314, 315, 316,
1131 298, 519, 299, 300, 301, 302, 303, 304, 305, 306,
1132 307, 308, 309, 310, 311, 312, 313, 314, 315, 316,
1133 298, 520, 299, 300, 301, 302, 303, 304, 305, 306,
1134 307, 308, 309, 310, 311, 312, 313, 314, 315, 316,
1135 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
1136 0, 0, 521, 298, 330, 299, 300, 301, 302, 303,
1137 304, 305, 306, 307, 308, 309, 310, 311, 312, 313,
1138 314, 315, 316, 189, 190, 0, 0, 0, 0, 10,
1139 11, 191, 192, 193, 194, 195, 196, 0, 0, 522,
1140 197, 0, 198, 0, 321, 0, 199, 200, 201, 202,
1141 322, 0, 0, 0, 0, 0, 0, 0, 0, 526,
1142 0, 0, 0, 323, 0, 0, 0, 203, 204, 0,
1143 0, 0, 205, 0, 206, 0, 0, 0, 324, 539,
1144 0, 0, 207, 0, 0, 0, 325, 0, 0, 0,
1145 0, 0, 0, 208, 0, 209, 210, 0, 0, 0,
1146 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
1147 0, 331, 0, 0, 0, 0, 211, 326, 0, 0,
1148 189, 190, 212, 0, 0, 213, 10, 11, 191, 192,
1149 193, 194, 195, 196, 0, 0, 0, 197, 0, 198,
1150 0, 0, 0, 199, 200, 201, 202, 0, 0, 0,
1151 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
1152 0, 0, 0, 0, 203, 204, 0, 0, 0, 205,
1153 0, 206, 0, 10, 11, 0, 0, 0, 0, 207,
1154 27, 0, 0, 0, 0, 0, 0, 0, 0, 0,
1155 208, 0, 209, 210, 0, 28, 0, 29, 0, 0,
1156 30, 0, 31, 32, 0, 33, 34, 0, 35, 0,
1157 0, 0, 0, 211, 0, 0, 0, 36, 0, 212,
1158 0, 0, 213, 0, 0, 0, 0, 0, 37, 38,
1159 0, 39, 40, 41, 0, 42, 43, 0, 0, 0,
1160 0, 0, 0, 0, 0, 0, 0, 0, 0, 44,
1161 0, 45, 46, 0, 0, 0, 0, 0, 0, 0,
1162 0, 0, 0, 0, 0, 47, 298, 463, 299, 300,
1163 301, 302, 303, 304, 305, 306, 307, 308, 309, 310,
1164 311, 312, 313, 314, 315, 316, 298, 0, 299, 300,
1165 301, 302, 303, 304, 305, 306, 307, 308, 309, 310,
1166 311, 312, 313, 314, 315, 316
1167 };
1168
1169 static const yytype_int16 yycheck[] =
1170 {
1171 2, 3, 25, 24, 19, 9, 154, 9, 68, 0,
1172 122, 94, 14, 435, 0, 437, 33, 34, 85, 86,
1173 24, 23, 24, 33, 34, 33, 34, 33, 34, 122,
1174 90, 33, 115, 116, 117, 118, 119, 120, 121, 122,
1175 123, 3, 4, 5, 6, 7, 8, 9, 10, 11,
1176 133, 12, 54, 122, 33, 34, 139, 140, 12, 7,
1177 127, 144, 33, 34, 66, 12, 33, 34, 29, 33,
1178 34, 42, 33, 34, 76, 29, 33, 34, 57, 33,
1179 34, 121, 29, 120, 124, 42, 33, 34, 70, 71,
1180 57, 93, 120, 95, 61, 340, 98, 342, 100, 344,
1181 102, 103, 56, 105, 106, 107, 73, 109, 125, 111,
1182 125, 126, 534, 535, 33, 34, 126, 125, 124, 120,
1183 91, 142, 143, 122, 121, 33, 34, 124, 121, 33,
1184 34, 124, 134, 124, 91, 120, 33, 34, 161, 120,
1185 142, 143, 103, 145, 123, 147, 128, 101, 102, 103,
1186 13, 153, 154, 57, 101, 102, 103, 65, 120, 123,
1187 57, 7, 164, 120, 27, 28, 249, 13, 170, 73,
1188 33, 34, 35, 36, 37, 38, 39, 40, 261, 262,
1189 120, 44, 120, 46, 120, 187, 188, 50, 51, 52,
1190 53, 121, 33, 34, 124, 122, 121, 83, 84, 124,
1191 120, 48, 120, 122, 120, 353, 120, 54, 71, 72,
1192 33, 34, 122, 76, 237, 78, 57, 40, 104, 121,
1193 67, 13, 124, 86, 33, 34, 121, 123, 12, 124,
1194 13, 40, 55, 125, 97, 82, 99, 100, 125, 241,
1195 63, 243, 65, 90, 246, 29, 55, 33, 34, 33,
1196 34, 253, 120, 268, 63, 257, 65, 120, 260, 28,
1197 124, 125, 264, 126, 33, 34, 129, 123, 124, 92,
1198 93, 273, 41, 122, 121, 120, 278, 120, 280, 123,
1199 120, 283, 120, 92, 93, 287, 288, 289, 120, 120,
1200 292, 293, 294, 12, 120, 14, 15, 16, 17, 18,
1201 19, 20, 21, 22, 23, 24, 25, 26, 27, 28,
1202 29, 30, 31, 334, 123, 120, 318, 125, 339, 120,
1203 341, 3, 4, 5, 6, 7, 8, 9, 10, 11,
1204 332, 124, 334, 33, 34, 35, 121, 339, 340, 341,
1205 342, 121, 344, 345, 29, 30, 31, 349, 7, 33,
1206 121, 353, 7, 7, 12, 357, 14, 15, 16, 17,
1207 18, 19, 20, 21, 22, 23, 24, 25, 26, 27,
1208 28, 29, 30, 31, 21, 22, 23, 24, 25, 26,
1209 27, 28, 29, 30, 31, 121, 407, 121, 121, 124,
1210 131, 120, 120, 416, 125, 125, 120, 138, 481, 120,
1211 120, 484, 121, 407, 12, 407, 14, 15, 16, 17,
1212 18, 19, 20, 21, 22, 23, 24, 25, 26, 27,
1213 28, 29, 30, 31, 12, 120, 120, 442, 443, 120,
1214 120, 433, 120, 435, 12, 437, 27, 28, 29, 30,
1215 31, 29, 120, 120, 120, 33, 34, 449, 189, 190,
1216 120, 29, 120, 120, 475, 33, 34, 120, 479, 120,
1217 125, 121, 42, 121, 547, 122, 124, 550, 56, 47,
1218 121, 212, 213, 475, 124, 120, 120, 479, 113, 114,
1219 115, 116, 117, 118, 119, 121, 509, 510, 25, 26,
1220 27, 28, 29, 30, 31, 121, 121, 121, 500, 18,
1221 19, 20, 21, 22, 23, 24, 25, 26, 27, 28,
1222 29, 30, 31, 101, 102, 103, 124, 120, 120, 120,
1223 120, 13, 120, 13, 123, 122, 549, 121, 120, 38,
1224 125, 121, 534, 535, 121, 537, 277, 121, 279, 124,
1225 281, 282, 121, 284, 285, 286, 548, 121, 13, 290,
1226 291, 121, 121, 121, 121, 121, 121, 298, 299, 300,
1227 301, 302, 303, 304, 305, 306, 307, 308, 309, 310,
1228 311, 312, 313, 314, 315, 316, 121, 12, 124, 121,
1229 12, 19, 20, 21, 22, 23, 24, 25, 26, 27,
1230 28, 29, 30, 31, 29, 121, 13, 29, 33, 34,
1231 120, 33, 34, 107, 13, 40, 121, 121, 40, 121,
1232 45, 121, 47, 45, 121, 47, 121, 120, 7, 120,
1233 22, 123, 120, 58, 121, 125, 58, 13, 63, 35,
1234 65, 63, 125, 65, 69, 121, 124, 69, 42, 74,
1235 121, 121, 74, 22, 123, 7, 253, 168, 331, 320,
1236 479, 142, 101, 21, 170, 14, 491, 92, 93, 94,
1237 92, 93, 94, 98, 60, -1, 98, -1, 103, 410,
1238 105, 103, -1, 105, -1, -1, -1, -1, -1, -1,
1239 -1, -1, -1, -1, -1, -1, -1, -1, 123, -1,
1240 125, -1, -1, 125, -1, -1, -1, -1, -1, -1,
1241 -1, -1, -1, -1, -1, -1, 447, -1, -1, -1,
1242 -1, 452, -1, 454, -1, -1, -1, 458, 459, -1,
1243 461, -1, 463, -1, -1, -1, 12, 468, 14, 15,
1244 16, 17, 18, 19, 20, 21, 22, 23, 24, 25,
1245 26, 27, 28, 29, 30, 31, 15, 16, 17, 18,
1246 19, 20, 21, 22, 23, 24, 25, 26, 27, 28,
1247 29, 30, 31, 12, 505, 14, 15, 16, 17, 18,
1248 19, 20, 21, 22, 23, 24, 25, 26, 27, 28,
1249 29, 30, 31, 12, -1, 14, 15, 16, 17, 18,
1250 19, 20, 21, 22, 23, 24, 25, 26, 27, 28,
1251 29, 30, 31, 12, -1, 14, 15, 16, 17, 18,
1252 19, 20, 21, 22, 23, 24, 25, 26, 27, 28,
1253 29, 30, 31, -1, -1, -1, -1, -1, -1, -1,
1254 -1, -1, -1, -1, -1, -1, -1, 12, 124, 14,
1255 15, 16, 17, 18, 19, 20, 21, 22, 23, 24,
1256 25, 26, 27, 28, 29, 30, 31, 16, 17, 18,
1257 19, 20, 21, 22, 23, 24, 25, 26, 27, 28,
1258 29, 30, 31, -1, 12, 124, 14, 15, 16, 17,
1259 18, 19, 20, 21, 22, 23, 24, 25, 26, 27,
1260 28, 29, 30, 31, 12, 124, 14, 15, 16, 17,
1261 18, 19, 20, 21, 22, 23, 24, 25, 26, 27,
1262 28, 29, 30, 31, 12, 124, 14, 15, 16, 17,
1263 18, 19, 20, 21, 22, 23, 24, 25, 26, 27,
1264 28, 29, 30, 31, -1, -1, -1, -1, -1, -1,
1265 -1, -1, -1, -1, -1, 12, 121, 14, 15, 16,
1266 17, 18, 19, 20, 21, 22, 23, 24, 25, 26,
1267 27, 28, 29, 30, 31, 17, 18, 19, 20, 21,
1268 22, 23, 24, 25, 26, 27, 28, 29, 30, 31,
1269 -1, -1, 12, 121, 14, 15, 16, 17, 18, 19,
1270 20, 21, 22, 23, 24, 25, 26, 27, 28, 29,
1271 30, 31, 12, 121, 14, 15, 16, 17, 18, 19,
1272 20, 21, 22, 23, 24, 25, 26, 27, 28, 29,
1273 30, 31, 12, 121, 14, 15, 16, 17, 18, 19,
1274 20, 21, 22, 23, 24, 25, 26, 27, 28, 29,
1275 30, 31, -1, -1, -1, -1, -1, -1, -1, -1,
1276 -1, -1, -1, 12, 121, 14, 15, 16, 17, 18,
1277 19, 20, 21, 22, 23, 24, 25, 26, 27, 28,
1278 29, 30, 31, -1, -1, -1, -1, -1, -1, -1,
1279 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
1280 12, 121, 14, 15, 16, 17, 18, 19, 20, 21,
1281 22, 23, 24, 25, 26, 27, 28, 29, 30, 31,
1282 12, 121, 14, 15, 16, 17, 18, 19, 20, 21,
1283 22, 23, 24, 25, 26, 27, 28, 29, 30, 31,
1284 12, 121, 14, 15, 16, 17, 18, 19, 20, 21,
1285 22, 23, 24, 25, 26, 27, 28, 29, 30, 31,
1286 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
1287 -1, -1, 121, 12, 13, 14, 15, 16, 17, 18,
1288 19, 20, 21, 22, 23, 24, 25, 26, 27, 28,
1289 29, 30, 31, 27, 28, -1, -1, -1, -1, 33,
1290 34, 35, 36, 37, 38, 39, 40, -1, -1, 121,
1291 44, -1, 46, -1, 48, -1, 50, 51, 52, 53,
1292 54, -1, -1, -1, -1, -1, -1, -1, -1, 121,
1293 -1, -1, -1, 67, -1, -1, -1, 71, 72, -1,
1294 -1, -1, 76, -1, 78, -1, -1, -1, 82, 121,
1295 -1, -1, 86, -1, -1, -1, 90, -1, -1, -1,
1296 -1, -1, -1, 97, -1, 99, 100, -1, -1, -1,
1297 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
1298 -1, 120, -1, -1, -1, -1, 120, 121, -1, -1,
1299 27, 28, 126, -1, -1, 129, 33, 34, 35, 36,
1300 37, 38, 39, 40, -1, -1, -1, 44, -1, 46,
1301 -1, -1, -1, 50, 51, 52, 53, -1, -1, -1,
1302 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
1303 -1, -1, -1, -1, 71, 72, -1, -1, -1, 76,
1304 -1, 78, -1, 33, 34, -1, -1, -1, -1, 86,
1305 40, -1, -1, -1, -1, -1, -1, -1, -1, -1,
1306 97, -1, 99, 100, -1, 55, -1, 57, -1, -1,
1307 60, -1, 62, 63, -1, 65, 66, -1, 68, -1,
1308 -1, -1, -1, 120, -1, -1, -1, 77, -1, 126,
1309 -1, -1, 129, -1, -1, -1, -1, -1, 88, 89,
1310 -1, 91, 92, 93, -1, 95, 96, -1, -1, -1,
1311 -1, -1, -1, -1, -1, -1, -1, -1, -1, 109,
1312 -1, 111, 112, -1, -1, -1, -1, -1, -1, -1,
1313 -1, -1, -1, -1, -1, 125, 12, 13, 14, 15,
1314 16, 17, 18, 19, 20, 21, 22, 23, 24, 25,
1315 26, 27, 28, 29, 30, 31, 12, -1, 14, 15,
1316 16, 17, 18, 19, 20, 21, 22, 23, 24, 25,
1317 26, 27, 28, 29, 30, 31
1318 };
1319
1320 /* YYSTOS[STATE-NUM] -- The (internal number of the) accessing
1321 symbol of state STATE-NUM. */
1322 static const yytype_uint8 yystos[] =
1323 {
1324 0, 113, 114, 115, 116, 117, 118, 119, 131, 132,
1325 33, 34, 122, 188, 189, 190, 196, 184, 196, 122,
1326 185, 186, 187, 144, 161, 171, 0, 40, 55, 57,
1327 60, 62, 63, 65, 66, 68, 77, 88, 89, 91,
1328 92, 93, 95, 96, 109, 111, 112, 125, 133, 137,
1329 180, 196, 33, 34, 57, 61, 73, 192, 193, 190,
1330 122, 7, 193, 187, 40, 55, 65, 145, 180, 196,
1331 12, 29, 40, 45, 47, 58, 65, 69, 74, 94,
1332 98, 103, 105, 125, 162, 163, 164, 165, 166, 170,
1333 180, 196, 124, 199, 120, 120, 120, 134, 120, 196,
1334 120, 122, 120, 120, 122, 120, 120, 120, 122, 120,
1335 122, 120, 124, 125, 197, 3, 4, 5, 6, 7,
1336 8, 9, 10, 11, 196, 13, 13, 123, 125, 192,
1337 181, 182, 125, 120, 120, 196, 197, 147, 148, 120,
1338 120, 196, 120, 120, 120, 120, 197, 65, 172, 196,
1339 181, 196, 138, 139, 120, 196, 28, 41, 141, 142,
1340 196, 171, 196, 196, 176, 196, 196, 196, 135, 196,
1341 136, 196, 181, 181, 181, 181, 181, 181, 181, 181,
1342 181, 122, 193, 193, 125, 33, 34, 57, 123, 27,
1343 28, 35, 36, 37, 38, 39, 40, 44, 46, 50,
1344 51, 52, 53, 71, 72, 76, 78, 86, 97, 99,
1345 100, 120, 126, 129, 183, 196, 123, 181, 196, 146,
1346 13, 120, 150, 183, 181, 181, 103, 165, 196, 47,
1347 170, 196, 181, 56, 101, 102, 103, 167, 168, 170,
1348 196, 120, 173, 124, 121, 121, 140, 196, 141, 7,
1349 33, 143, 121, 199, 123, 121, 121, 124, 123, 177,
1350 196, 7, 7, 121, 144, 121, 188, 121, 194, 125,
1351 125, 196, 125, 191, 196, 183, 183, 120, 120, 120,
1352 120, 120, 120, 120, 120, 120, 120, 120, 120, 120,
1353 120, 120, 120, 120, 120, 183, 183, 183, 12, 14,
1354 15, 16, 17, 18, 19, 20, 21, 22, 23, 24,
1355 25, 26, 27, 28, 29, 30, 31, 125, 124, 121,
1356 122, 48, 54, 67, 82, 90, 121, 151, 42, 152,
1357 13, 120, 124, 121, 120, 121, 121, 121, 121, 120,
1358 120, 120, 120, 121, 199, 126, 196, 13, 196, 124,
1359 196, 121, 181, 120, 142, 196, 35, 178, 196, 181,
1360 181, 123, 123, 193, 73, 122, 125, 196, 183, 196,
1361 183, 196, 183, 183, 196, 183, 183, 183, 196, 196,
1362 196, 183, 183, 196, 196, 196, 121, 183, 183, 183,
1363 183, 183, 183, 183, 183, 183, 183, 183, 183, 183,
1364 183, 183, 183, 183, 183, 183, 196, 161, 13, 121,
1365 120, 38, 153, 121, 151, 196, 169, 170, 168, 170,
1366 168, 56, 168, 196, 121, 85, 86, 127, 174, 121,
1367 196, 121, 141, 124, 42, 91, 179, 196, 121, 121,
1368 125, 198, 13, 195, 121, 121, 121, 124, 121, 124,
1369 121, 121, 124, 121, 124, 121, 121, 121, 124, 124,
1370 121, 124, 121, 13, 121, 123, 13, 183, 120, 107,
1371 154, 13, 121, 121, 121, 199, 121, 121, 121, 120,
1372 121, 7, 121, 196, 120, 179, 125, 120, 179, 123,
1373 193, 193, 183, 196, 183, 183, 183, 183, 183, 183,
1374 22, 156, 157, 121, 183, 120, 149, 13, 170, 169,
1375 181, 121, 181, 35, 125, 198, 121, 121, 121, 121,
1376 121, 121, 121, 196, 42, 158, 121, 183, 83, 84,
1377 104, 155, 121, 199, 121, 121, 123, 22, 159, 121,
1378 70, 71, 128, 175, 179, 179, 196, 7, 13, 160,
1379 7, 181, 196, 199, 181
1380 };
1381
1382 /* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */
1383 static const yytype_uint8 yyr1[] =
1384 {
1385 0, 130, 131, 131, 131, 131, 131, 131, 131, 132,
1386 132, 133, 133, 134, 133, 133, 133, 133, 133, 133,
1387 133, 133, 133, 135, 133, 133, 136, 133, 133, 133,
1388 133, 133, 133, 133, 137, 139, 138, 140, 140, 140,
1389 141, 141, 142, 142, 143, 142, 144, 144, 145, 145,
1390 145, 145, 146, 145, 148, 149, 147, 150, 150, 150,
1391 150, 150, 150, 151, 151, 151, 151, 151, 152, 152,
1392 153, 153, 154, 154, 155, 155, 155, 155, 156, 157,
1393 157, 158, 158, 159, 159, 160, 160, 161, 161, 162,
1394 162, 162, 162, 162, 162, 162, 162, 162, 163, 163,
1395 163, 163, 163, 164, 164, 165, 165, 166, 166, 167,
1396 167, 167, 167, 168, 168, 168, 168, 169, 169, 170,
1397 170, 170, 171, 171, 172, 172, 172, 173, 173, 173,
1398 174, 174, 174, 175, 175, 175, 176, 176, 177, 178,
1399 178, 179, 179, 179, 179, 179, 180, 180, 180, 180,
1400 180, 180, 180, 180, 180, 180, 180, 180, 182, 181,
1401 183, 183, 183, 183, 183, 183, 183, 183, 183, 183,
1402 183, 183, 183, 183, 183, 183, 183, 183, 183, 183,
1403 183, 183, 183, 183, 183, 183, 183, 183, 183, 183,
1404 183, 183, 183, 183, 183, 183, 183, 183, 183, 183,
1405 183, 183, 183, 183, 183, 183, 184, 185, 186, 186,
1406 187, 188, 189, 189, 190, 190, 190, 191, 191, 192,
1407 192, 192, 192, 192, 193, 193, 193, 193, 194, 193,
1408 195, 193, 193, 193, 196, 196, 197, 197, 198, 198,
1409 199, 199
1410 };
1411
1412 /* YYR2[YYN] -- Number of symbols on the right hand side of rule YYN. */
1413 static const yytype_int8 yyr2[] =
1414 {
1415 0, 2, 2, 2, 2, 2, 2, 2, 2, 2,
1416 0, 4, 1, 0, 5, 1, 4, 4, 4, 4,
1417 8, 4, 4, 0, 5, 4, 0, 5, 4, 2,
1418 6, 2, 1, 1, 4, 0, 2, 1, 2, 3,
1419 1, 3, 1, 2, 0, 5, 2, 0, 4, 2,
1420 6, 2, 0, 7, 0, 0, 7, 1, 3, 2,
1421 4, 4, 5, 1, 1, 1, 1, 1, 0, 4,
1422 0, 4, 0, 4, 0, 1, 1, 1, 5, 2,
1423 0, 3, 0, 3, 0, 2, 0, 0, 2, 2,
1424 1, 4, 6, 4, 1, 4, 2, 1, 1, 1,
1425 1, 1, 1, 1, 4, 1, 4, 1, 4, 3,
1426 1, 6, 4, 1, 4, 4, 4, 3, 1, 1,
1427 1, 1, 3, 0, 10, 2, 0, 3, 4, 0,
1428 1, 1, 1, 1, 1, 1, 2, 0, 4, 1,
1429 1, 0, 2, 2, 5, 5, 3, 3, 3, 3,
1430 3, 3, 3, 3, 3, 6, 6, 6, 0, 2,
1431 3, 2, 2, 2, 2, 3, 3, 3, 3, 3,
1432 3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
1433 3, 3, 3, 5, 1, 1, 6, 6, 4, 1,
1434 4, 4, 4, 4, 4, 4, 4, 4, 4, 6,
1435 4, 6, 6, 4, 6, 6, 3, 1, 1, 2,
1436 5, 1, 1, 2, 4, 5, 6, 1, 2, 0,
1437 2, 4, 4, 8, 1, 1, 3, 3, 0, 7,
1438 0, 9, 1, 3, 1, 1, 1, 1, 1, 0,
1439 1, 0
1440 };
1441
1442
1443 #define yyerrok (yyerrstatus = 0)
1444 #define yyclearin (yychar = YYEMPTY)
1445 #define YYEMPTY (-2)
1446 #define YYEOF 0
1447
1448 #define YYACCEPT goto yyacceptlab
1449 #define YYABORT goto yyabortlab
1450 #define YYERROR goto yyerrorlab
1451
1452
1453 #define YYRECOVERING() (!!yyerrstatus)
1454
1455 #define YYBACKUP(Token, Value) \
1456 do \
1457 if (yychar == YYEMPTY) \
1458 { \
1459 yychar = (Token); \
1460 yylval = (Value); \
1461 YYPOPSTACK (yylen); \
1462 yystate = *yyssp; \
1463 goto yybackup; \
1464 } \
1465 else \
1466 { \
1467 yyerror (closure, YY_("syntax error: cannot back up")); \
1468 YYERROR; \
1469 } \
1470 while (0)
1471
1472 /* Error token number */
1473 #define YYTERROR 1
1474 #define YYERRCODE 256
1475
1476
1477
1478 /* Enable debugging if requested. */
1479 #if YYDEBUG
1480
1481 # ifndef YYFPRINTF
1482 # include <stdio.h> /* INFRINGES ON USER NAME SPACE */
1483 # define YYFPRINTF fprintf
1484 # endif
1485
1486 # define YYDPRINTF(Args) \
1487 do { \
1488 if (yydebug) \
1489 YYFPRINTF Args; \
1490 } while (0)
1491
1492 /* This macro is provided for backward compatibility. */
1493 #ifndef YY_LOCATION_PRINT
1494 # define YY_LOCATION_PRINT(File, Loc) ((void) 0)
1495 #endif
1496
1497
1498 # define YY_SYMBOL_PRINT(Title, Type, Value, Location) \
1499 do { \
1500 if (yydebug) \
1501 { \
1502 YYFPRINTF (stderr, "%s ", Title); \
1503 yy_symbol_print (stderr, \
1504 Type, Value, closure); \
1505 YYFPRINTF (stderr, "\n"); \
1506 } \
1507 } while (0)
1508
1509
1510 /*-----------------------------------.
1511 | Print this symbol's value on YYO. |
1512 `-----------------------------------*/
1513
1514 static void
yy_symbol_value_print(FILE * yyo,int yytype,YYSTYPE const * const yyvaluep,void * closure)1515 yy_symbol_value_print (FILE *yyo, int yytype, YYSTYPE const * const yyvaluep, void* closure)
1516 {
1517 FILE *yyoutput = yyo;
1518 YYUSE (yyoutput);
1519 YYUSE (closure);
1520 if (!yyvaluep)
1521 return;
1522 # ifdef YYPRINT
1523 if (yytype < YYNTOKENS)
1524 YYPRINT (yyo, yytoknum[yytype], *yyvaluep);
1525 # endif
1526 YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
1527 YYUSE (yytype);
1528 YY_IGNORE_MAYBE_UNINITIALIZED_END
1529 }
1530
1531
1532 /*---------------------------.
1533 | Print this symbol on YYO. |
1534 `---------------------------*/
1535
1536 static void
yy_symbol_print(FILE * yyo,int yytype,YYSTYPE const * const yyvaluep,void * closure)1537 yy_symbol_print (FILE *yyo, int yytype, YYSTYPE const * const yyvaluep, void* closure)
1538 {
1539 YYFPRINTF (yyo, "%s %s (",
1540 yytype < YYNTOKENS ? "token" : "nterm", yytname[yytype]);
1541
1542 yy_symbol_value_print (yyo, yytype, yyvaluep, closure);
1543 YYFPRINTF (yyo, ")");
1544 }
1545
1546 /*------------------------------------------------------------------.
1547 | yy_stack_print -- Print the state stack from its BOTTOM up to its |
1548 | TOP (included). |
1549 `------------------------------------------------------------------*/
1550
1551 static void
yy_stack_print(yy_state_t * yybottom,yy_state_t * yytop)1552 yy_stack_print (yy_state_t *yybottom, yy_state_t *yytop)
1553 {
1554 YYFPRINTF (stderr, "Stack now");
1555 for (; yybottom <= yytop; yybottom++)
1556 {
1557 int yybot = *yybottom;
1558 YYFPRINTF (stderr, " %d", yybot);
1559 }
1560 YYFPRINTF (stderr, "\n");
1561 }
1562
1563 # define YY_STACK_PRINT(Bottom, Top) \
1564 do { \
1565 if (yydebug) \
1566 yy_stack_print ((Bottom), (Top)); \
1567 } while (0)
1568
1569
1570 /*------------------------------------------------.
1571 | Report that the YYRULE is going to be reduced. |
1572 `------------------------------------------------*/
1573
1574 static void
yy_reduce_print(yy_state_t * yyssp,YYSTYPE * yyvsp,int yyrule,void * closure)1575 yy_reduce_print (yy_state_t *yyssp, YYSTYPE *yyvsp, int yyrule, void* closure)
1576 {
1577 int yylno = yyrline[yyrule];
1578 int yynrhs = yyr2[yyrule];
1579 int yyi;
1580 YYFPRINTF (stderr, "Reducing stack by rule %d (line %d):\n",
1581 yyrule - 1, yylno);
1582 /* The symbols being reduced. */
1583 for (yyi = 0; yyi < yynrhs; yyi++)
1584 {
1585 YYFPRINTF (stderr, " $%d = ", yyi + 1);
1586 yy_symbol_print (stderr,
1587 yystos[yyssp[yyi + 1 - yynrhs]],
1588 &yyvsp[(yyi + 1) - (yynrhs)]
1589 , closure);
1590 YYFPRINTF (stderr, "\n");
1591 }
1592 }
1593
1594 # define YY_REDUCE_PRINT(Rule) \
1595 do { \
1596 if (yydebug) \
1597 yy_reduce_print (yyssp, yyvsp, Rule, closure); \
1598 } while (0)
1599
1600 /* Nonzero means print parse trace. It is left uninitialized so that
1601 multiple parsers can coexist. */
1602 int yydebug;
1603 #else /* !YYDEBUG */
1604 # define YYDPRINTF(Args)
1605 # define YY_SYMBOL_PRINT(Title, Type, Value, Location)
1606 # define YY_STACK_PRINT(Bottom, Top)
1607 # define YY_REDUCE_PRINT(Rule)
1608 #endif /* !YYDEBUG */
1609
1610
1611 /* YYINITDEPTH -- initial size of the parser's stacks. */
1612 #ifndef YYINITDEPTH
1613 # define YYINITDEPTH 200
1614 #endif
1615
1616 /* YYMAXDEPTH -- maximum size the stacks can grow to (effective only
1617 if the built-in stack extension method is used).
1618
1619 Do not make this value too large; the results are undefined if
1620 YYSTACK_ALLOC_MAXIMUM < YYSTACK_BYTES (YYMAXDEPTH)
1621 evaluated with infinite-precision integer arithmetic. */
1622
1623 #ifndef YYMAXDEPTH
1624 # define YYMAXDEPTH 10000
1625 #endif
1626
1627
1628 #if YYERROR_VERBOSE
1629
1630 # ifndef yystrlen
1631 # if defined __GLIBC__ && defined _STRING_H
1632 # define yystrlen(S) (YY_CAST (YYPTRDIFF_T, strlen (S)))
1633 # else
1634 /* Return the length of YYSTR. */
1635 static YYPTRDIFF_T
yystrlen(const char * yystr)1636 yystrlen (const char *yystr)
1637 {
1638 YYPTRDIFF_T yylen;
1639 for (yylen = 0; yystr[yylen]; yylen++)
1640 continue;
1641 return yylen;
1642 }
1643 # endif
1644 # endif
1645
1646 # ifndef yystpcpy
1647 # if defined __GLIBC__ && defined _STRING_H && defined _GNU_SOURCE
1648 # define yystpcpy stpcpy
1649 # else
1650 /* Copy YYSRC to YYDEST, returning the address of the terminating '\0' in
1651 YYDEST. */
1652 static char *
yystpcpy(char * yydest,const char * yysrc)1653 yystpcpy (char *yydest, const char *yysrc)
1654 {
1655 char *yyd = yydest;
1656 const char *yys = yysrc;
1657
1658 while ((*yyd++ = *yys++) != '\0')
1659 continue;
1660
1661 return yyd - 1;
1662 }
1663 # endif
1664 # endif
1665
1666 # ifndef yytnamerr
1667 /* Copy to YYRES the contents of YYSTR after stripping away unnecessary
1668 quotes and backslashes, so that it's suitable for yyerror. The
1669 heuristic is that double-quoting is unnecessary unless the string
1670 contains an apostrophe, a comma, or backslash (other than
1671 backslash-backslash). YYSTR is taken from yytname. If YYRES is
1672 null, do not copy; instead, return the length of what the result
1673 would have been. */
1674 static YYPTRDIFF_T
yytnamerr(char * yyres,const char * yystr)1675 yytnamerr (char *yyres, const char *yystr)
1676 {
1677 if (*yystr == '"')
1678 {
1679 YYPTRDIFF_T yyn = 0;
1680 char const *yyp = yystr;
1681
1682 for (;;)
1683 switch (*++yyp)
1684 {
1685 case '\'':
1686 case ',':
1687 goto do_not_strip_quotes;
1688
1689 case '\\':
1690 if (*++yyp != '\\')
1691 goto do_not_strip_quotes;
1692 else
1693 goto append;
1694
1695 append:
1696 default:
1697 if (yyres)
1698 yyres[yyn] = *yyp;
1699 yyn++;
1700 break;
1701
1702 case '"':
1703 if (yyres)
1704 yyres[yyn] = '\0';
1705 return yyn;
1706 }
1707 do_not_strip_quotes: ;
1708 }
1709
1710 if (yyres)
1711 return yystpcpy (yyres, yystr) - yyres;
1712 else
1713 return yystrlen (yystr);
1714 }
1715 # endif
1716
1717 /* Copy into *YYMSG, which is of size *YYMSG_ALLOC, an error message
1718 about the unexpected token YYTOKEN for the state stack whose top is
1719 YYSSP.
1720
1721 Return 0 if *YYMSG was successfully written. Return 1 if *YYMSG is
1722 not large enough to hold the message. In that case, also set
1723 *YYMSG_ALLOC to the required number of bytes. Return 2 if the
1724 required number of bytes is too large to store. */
1725 static int
yysyntax_error(YYPTRDIFF_T * yymsg_alloc,char ** yymsg,yy_state_t * yyssp,int yytoken)1726 yysyntax_error (YYPTRDIFF_T *yymsg_alloc, char **yymsg,
1727 yy_state_t *yyssp, int yytoken)
1728 {
1729 enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 };
1730 /* Internationalized format string. */
1731 const char *yyformat = YY_NULLPTR;
1732 /* Arguments of yyformat: reported tokens (one for the "unexpected",
1733 one per "expected"). */
1734 char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM];
1735 /* Actual size of YYARG. */
1736 int yycount = 0;
1737 /* Cumulated lengths of YYARG. */
1738 YYPTRDIFF_T yysize = 0;
1739
1740 /* There are many possibilities here to consider:
1741 - If this state is a consistent state with a default action, then
1742 the only way this function was invoked is if the default action
1743 is an error action. In that case, don't check for expected
1744 tokens because there are none.
1745 - The only way there can be no lookahead present (in yychar) is if
1746 this state is a consistent state with a default action. Thus,
1747 detecting the absence of a lookahead is sufficient to determine
1748 that there is no unexpected or expected token to report. In that
1749 case, just report a simple "syntax error".
1750 - Don't assume there isn't a lookahead just because this state is a
1751 consistent state with a default action. There might have been a
1752 previous inconsistent state, consistent state with a non-default
1753 action, or user semantic action that manipulated yychar.
1754 - Of course, the expected token list depends on states to have
1755 correct lookahead information, and it depends on the parser not
1756 to perform extra reductions after fetching a lookahead from the
1757 scanner and before detecting a syntax error. Thus, state merging
1758 (from LALR or IELR) and default reductions corrupt the expected
1759 token list. However, the list is correct for canonical LR with
1760 one exception: it will still contain any token that will not be
1761 accepted due to an error action in a later state.
1762 */
1763 if (yytoken != YYEMPTY)
1764 {
1765 int yyn = yypact[*yyssp];
1766 YYPTRDIFF_T yysize0 = yytnamerr (YY_NULLPTR, yytname[yytoken]);
1767 yysize = yysize0;
1768 yyarg[yycount++] = yytname[yytoken];
1769 if (!yypact_value_is_default (yyn))
1770 {
1771 /* Start YYX at -YYN if negative to avoid negative indexes in
1772 YYCHECK. In other words, skip the first -YYN actions for
1773 this state because they are default actions. */
1774 int yyxbegin = yyn < 0 ? -yyn : 0;
1775 /* Stay within bounds of both yycheck and yytname. */
1776 int yychecklim = YYLAST - yyn + 1;
1777 int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS;
1778 int yyx;
1779
1780 for (yyx = yyxbegin; yyx < yyxend; ++yyx)
1781 if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR
1782 && !yytable_value_is_error (yytable[yyx + yyn]))
1783 {
1784 if (yycount == YYERROR_VERBOSE_ARGS_MAXIMUM)
1785 {
1786 yycount = 1;
1787 yysize = yysize0;
1788 break;
1789 }
1790 yyarg[yycount++] = yytname[yyx];
1791 {
1792 YYPTRDIFF_T yysize1
1793 = yysize + yytnamerr (YY_NULLPTR, yytname[yyx]);
1794 if (yysize <= yysize1 && yysize1 <= YYSTACK_ALLOC_MAXIMUM)
1795 yysize = yysize1;
1796 else
1797 return 2;
1798 }
1799 }
1800 }
1801 }
1802
1803 switch (yycount)
1804 {
1805 # define YYCASE_(N, S) \
1806 case N: \
1807 yyformat = S; \
1808 break
1809 default: /* Avoid compiler warnings. */
1810 YYCASE_(0, YY_("syntax error"));
1811 YYCASE_(1, YY_("syntax error, unexpected %s"));
1812 YYCASE_(2, YY_("syntax error, unexpected %s, expecting %s"));
1813 YYCASE_(3, YY_("syntax error, unexpected %s, expecting %s or %s"));
1814 YYCASE_(4, YY_("syntax error, unexpected %s, expecting %s or %s or %s"));
1815 YYCASE_(5, YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s"));
1816 # undef YYCASE_
1817 }
1818
1819 {
1820 /* Don't count the "%s"s in the final size, but reserve room for
1821 the terminator. */
1822 YYPTRDIFF_T yysize1 = yysize + (yystrlen (yyformat) - 2 * yycount) + 1;
1823 if (yysize <= yysize1 && yysize1 <= YYSTACK_ALLOC_MAXIMUM)
1824 yysize = yysize1;
1825 else
1826 return 2;
1827 }
1828
1829 if (*yymsg_alloc < yysize)
1830 {
1831 *yymsg_alloc = 2 * yysize;
1832 if (! (yysize <= *yymsg_alloc
1833 && *yymsg_alloc <= YYSTACK_ALLOC_MAXIMUM))
1834 *yymsg_alloc = YYSTACK_ALLOC_MAXIMUM;
1835 return 1;
1836 }
1837
1838 /* Avoid sprintf, as that infringes on the user's name space.
1839 Don't have undefined behavior even if the translation
1840 produced a string with the wrong number of "%s"s. */
1841 {
1842 char *yyp = *yymsg;
1843 int yyi = 0;
1844 while ((*yyp = *yyformat) != '\0')
1845 if (*yyp == '%' && yyformat[1] == 's' && yyi < yycount)
1846 {
1847 yyp += yytnamerr (yyp, yyarg[yyi++]);
1848 yyformat += 2;
1849 }
1850 else
1851 {
1852 ++yyp;
1853 ++yyformat;
1854 }
1855 }
1856 return 0;
1857 }
1858 #endif /* YYERROR_VERBOSE */
1859
1860 /*-----------------------------------------------.
1861 | Release the memory associated to this symbol. |
1862 `-----------------------------------------------*/
1863
1864 static void
yydestruct(const char * yymsg,int yytype,YYSTYPE * yyvaluep,void * closure)1865 yydestruct (const char *yymsg, int yytype, YYSTYPE *yyvaluep, void* closure)
1866 {
1867 YYUSE (yyvaluep);
1868 YYUSE (closure);
1869 if (!yymsg)
1870 yymsg = "Deleting";
1871 YY_SYMBOL_PRINT (yymsg, yytype, yyvaluep, yylocationp);
1872
1873 YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
1874 YYUSE (yytype);
1875 YY_IGNORE_MAYBE_UNINITIALIZED_END
1876 }
1877
1878
1879
1880
1881 /*----------.
1882 | yyparse. |
1883 `----------*/
1884
1885 int
yyparse(void * closure)1886 yyparse (void* closure)
1887 {
1888 /* The lookahead symbol. */
1889 int yychar;
1890
1891
1892 /* The semantic value of the lookahead symbol. */
1893 /* Default value used for initialization, for pacifying older GCCs
1894 or non-GCC compilers. */
1895 YY_INITIAL_VALUE (static YYSTYPE yyval_default;)
1896 YYSTYPE yylval YY_INITIAL_VALUE (= yyval_default);
1897
1898 /* Number of syntax errors so far. */
1899 int yynerrs;
1900
1901 yy_state_fast_t yystate;
1902 /* Number of tokens to shift before error messages enabled. */
1903 int yyerrstatus;
1904
1905 /* The stacks and their tools:
1906 'yyss': related to states.
1907 'yyvs': related to semantic values.
1908
1909 Refer to the stacks through separate pointers, to allow yyoverflow
1910 to reallocate them elsewhere. */
1911
1912 /* The state stack. */
1913 yy_state_t yyssa[YYINITDEPTH];
1914 yy_state_t *yyss;
1915 yy_state_t *yyssp;
1916
1917 /* The semantic value stack. */
1918 YYSTYPE yyvsa[YYINITDEPTH];
1919 YYSTYPE *yyvs;
1920 YYSTYPE *yyvsp;
1921
1922 YYPTRDIFF_T yystacksize;
1923
1924 int yyn;
1925 int yyresult;
1926 /* Lookahead token as an internal (translated) token number. */
1927 int yytoken = 0;
1928 /* The variables used to return semantic value and location from the
1929 action routines. */
1930 YYSTYPE yyval;
1931
1932 #if YYERROR_VERBOSE
1933 /* Buffer for error messages, and its allocated size. */
1934 char yymsgbuf[128];
1935 char *yymsg = yymsgbuf;
1936 YYPTRDIFF_T yymsg_alloc = sizeof yymsgbuf;
1937 #endif
1938
1939 #define YYPOPSTACK(N) (yyvsp -= (N), yyssp -= (N))
1940
1941 /* The number of symbols on the RHS of the reduced rule.
1942 Keep to zero when no symbol should be popped. */
1943 int yylen = 0;
1944
1945 yyssp = yyss = yyssa;
1946 yyvsp = yyvs = yyvsa;
1947 yystacksize = YYINITDEPTH;
1948
1949 YYDPRINTF ((stderr, "Starting parse\n"));
1950
1951 yystate = 0;
1952 yyerrstatus = 0;
1953 yynerrs = 0;
1954 yychar = YYEMPTY; /* Cause a token to be read. */
1955 goto yysetstate;
1956
1957
1958 /*------------------------------------------------------------.
1959 | yynewstate -- push a new state, which is found in yystate. |
1960 `------------------------------------------------------------*/
1961 yynewstate:
1962 /* In all cases, when you get here, the value and location stacks
1963 have just been pushed. So pushing a state here evens the stacks. */
1964 yyssp++;
1965
1966
1967 /*--------------------------------------------------------------------.
1968 | yysetstate -- set current state (the top of the stack) to yystate. |
1969 `--------------------------------------------------------------------*/
1970 yysetstate:
1971 YYDPRINTF ((stderr, "Entering state %d\n", yystate));
1972 YY_ASSERT (0 <= yystate && yystate < YYNSTATES);
1973 YY_IGNORE_USELESS_CAST_BEGIN
1974 *yyssp = YY_CAST (yy_state_t, yystate);
1975 YY_IGNORE_USELESS_CAST_END
1976
1977 if (yyss + yystacksize - 1 <= yyssp)
1978 #if !defined yyoverflow && !defined YYSTACK_RELOCATE
1979 goto yyexhaustedlab;
1980 #else
1981 {
1982 /* Get the current used size of the three stacks, in elements. */
1983 YYPTRDIFF_T yysize = yyssp - yyss + 1;
1984
1985 # if defined yyoverflow
1986 {
1987 /* Give user a chance to reallocate the stack. Use copies of
1988 these so that the &'s don't force the real ones into
1989 memory. */
1990 yy_state_t *yyss1 = yyss;
1991 YYSTYPE *yyvs1 = yyvs;
1992
1993 /* Each stack pointer address is followed by the size of the
1994 data in use in that stack, in bytes. This used to be a
1995 conditional around just the two extra args, but that might
1996 be undefined if yyoverflow is a macro. */
1997 yyoverflow (YY_("memory exhausted"),
1998 &yyss1, yysize * YYSIZEOF (*yyssp),
1999 &yyvs1, yysize * YYSIZEOF (*yyvsp),
2000 &yystacksize);
2001 yyss = yyss1;
2002 yyvs = yyvs1;
2003 }
2004 # else /* defined YYSTACK_RELOCATE */
2005 /* Extend the stack our own way. */
2006 if (YYMAXDEPTH <= yystacksize)
2007 goto yyexhaustedlab;
2008 yystacksize *= 2;
2009 if (YYMAXDEPTH < yystacksize)
2010 yystacksize = YYMAXDEPTH;
2011
2012 {
2013 yy_state_t *yyss1 = yyss;
2014 union yyalloc *yyptr =
2015 YY_CAST (union yyalloc *,
2016 YYSTACK_ALLOC (YY_CAST (YYSIZE_T, YYSTACK_BYTES (yystacksize))));
2017 if (! yyptr)
2018 goto yyexhaustedlab;
2019 YYSTACK_RELOCATE (yyss_alloc, yyss);
2020 YYSTACK_RELOCATE (yyvs_alloc, yyvs);
2021 # undef YYSTACK_RELOCATE
2022 if (yyss1 != yyssa)
2023 YYSTACK_FREE (yyss1);
2024 }
2025 # endif
2026
2027 yyssp = yyss + yysize - 1;
2028 yyvsp = yyvs + yysize - 1;
2029
2030 YY_IGNORE_USELESS_CAST_BEGIN
2031 YYDPRINTF ((stderr, "Stack size increased to %ld\n",
2032 YY_CAST (long, yystacksize)));
2033 YY_IGNORE_USELESS_CAST_END
2034
2035 if (yyss + yystacksize - 1 <= yyssp)
2036 YYABORT;
2037 }
2038 #endif /* !defined yyoverflow && !defined YYSTACK_RELOCATE */
2039
2040 if (yystate == YYFINAL)
2041 YYACCEPT;
2042
2043 goto yybackup;
2044
2045
2046 /*-----------.
2047 | yybackup. |
2048 `-----------*/
2049 yybackup:
2050 /* Do appropriate processing given the current state. Read a
2051 lookahead token if we need one and don't already have one. */
2052
2053 /* First try to decide what to do without reference to lookahead token. */
2054 yyn = yypact[yystate];
2055 if (yypact_value_is_default (yyn))
2056 goto yydefault;
2057
2058 /* Not known => get a lookahead token if don't already have one. */
2059
2060 /* YYCHAR is either YYEMPTY or YYEOF or a valid lookahead symbol. */
2061 if (yychar == YYEMPTY)
2062 {
2063 YYDPRINTF ((stderr, "Reading a token: "));
2064 yychar = yylex (&yylval, closure);
2065 }
2066
2067 if (yychar <= YYEOF)
2068 {
2069 yychar = yytoken = YYEOF;
2070 YYDPRINTF ((stderr, "Now at end of input.\n"));
2071 }
2072 else
2073 {
2074 yytoken = YYTRANSLATE (yychar);
2075 YY_SYMBOL_PRINT ("Next token is", yytoken, &yylval, &yylloc);
2076 }
2077
2078 /* If the proper action on seeing token YYTOKEN is to reduce or to
2079 detect an error, take that action. */
2080 yyn += yytoken;
2081 if (yyn < 0 || YYLAST < yyn || yycheck[yyn] != yytoken)
2082 goto yydefault;
2083 yyn = yytable[yyn];
2084 if (yyn <= 0)
2085 {
2086 if (yytable_value_is_error (yyn))
2087 goto yyerrlab;
2088 yyn = -yyn;
2089 goto yyreduce;
2090 }
2091
2092 /* Count tokens shifted since error; after three, turn off error
2093 status. */
2094 if (yyerrstatus)
2095 yyerrstatus--;
2096
2097 /* Shift the lookahead token. */
2098 YY_SYMBOL_PRINT ("Shifting", yytoken, &yylval, &yylloc);
2099 yystate = yyn;
2100 YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
2101 *++yyvsp = yylval;
2102 YY_IGNORE_MAYBE_UNINITIALIZED_END
2103
2104 /* Discard the shifted token. */
2105 yychar = YYEMPTY;
2106 goto yynewstate;
2107
2108
2109 /*-----------------------------------------------------------.
2110 | yydefault -- do the default action for the current state. |
2111 `-----------------------------------------------------------*/
2112 yydefault:
2113 yyn = yydefact[yystate];
2114 if (yyn == 0)
2115 goto yyerrlab;
2116 goto yyreduce;
2117
2118
2119 /*-----------------------------.
2120 | yyreduce -- do a reduction. |
2121 `-----------------------------*/
2122 yyreduce:
2123 /* yyn is the number of a rule to reduce with. */
2124 yylen = yyr2[yyn];
2125
2126 /* If YYLEN is nonzero, implement the default value of the action:
2127 '$$ = $1'.
2128
2129 Otherwise, the following line sets YYVAL to garbage.
2130 This behavior is undocumented and Bison
2131 users should not rely upon it. Assigning to YYVAL
2132 unconditionally makes the parser a bit smaller, and it avoids a
2133 GCC warning that YYVAL may be used uninitialized. */
2134 yyval = yyvsp[1-yylen];
2135
2136
2137 YY_REDUCE_PRINT (yyn);
2138 switch (yyn)
2139 {
2140 case 12:
2141 #line 255 "yyscript.y"
2142 { script_set_common_allocation(closure, 1); }
2143 #line 2144 "yyscript.c"
2144 break;
2145
2146 case 13:
2147 #line 257 "yyscript.y"
2148 { script_start_group(closure); }
2149 #line 2150 "yyscript.c"
2150 break;
2151
2152 case 14:
2153 #line 259 "yyscript.y"
2154 { script_end_group(closure); }
2155 #line 2156 "yyscript.c"
2156 break;
2157
2158 case 15:
2159 #line 261 "yyscript.y"
2160 { script_set_common_allocation(closure, 0); }
2161 #line 2162 "yyscript.c"
2162 break;
2163
2164 case 18:
2165 #line 265 "yyscript.y"
2166 { script_parse_option(closure, (yyvsp[-1].string).value, (yyvsp[-1].string).length); }
2167 #line 2168 "yyscript.c"
2168 break;
2169
2170 case 19:
2171 #line 267 "yyscript.y"
2172 {
2173 if (!script_check_output_format(closure, (yyvsp[-1].string).value, (yyvsp[-1].string).length,
2174 NULL, 0, NULL, 0))
2175 YYABORT;
2176 }
2177 #line 2178 "yyscript.c"
2178 break;
2179
2180 case 20:
2181 #line 273 "yyscript.y"
2182 {
2183 if (!script_check_output_format(closure, (yyvsp[-5].string).value, (yyvsp[-5].string).length,
2184 (yyvsp[-3].string).value, (yyvsp[-3].string).length,
2185 (yyvsp[-1].string).value, (yyvsp[-1].string).length))
2186 YYABORT;
2187 }
2188 #line 2189 "yyscript.c"
2189 break;
2190
2191 case 22:
2192 #line 281 "yyscript.y"
2193 { script_add_search_dir(closure, (yyvsp[-1].string).value, (yyvsp[-1].string).length); }
2194 #line 2195 "yyscript.c"
2195 break;
2196
2197 case 23:
2198 #line 283 "yyscript.y"
2199 { script_start_sections(closure); }
2200 #line 2201 "yyscript.c"
2201 break;
2202
2203 case 24:
2204 #line 285 "yyscript.y"
2205 { script_finish_sections(closure); }
2206 #line 2207 "yyscript.c"
2207 break;
2208
2209 case 25:
2210 #line 287 "yyscript.y"
2211 { script_set_target(closure, (yyvsp[-1].string).value, (yyvsp[-1].string).length); }
2212 #line 2213 "yyscript.c"
2213 break;
2214
2215 case 26:
2216 #line 289 "yyscript.y"
2217 { script_push_lex_into_version_mode(closure); }
2218 #line 2219 "yyscript.c"
2219 break;
2220
2221 case 27:
2222 #line 291 "yyscript.y"
2223 { script_pop_lex_mode(closure); }
2224 #line 2225 "yyscript.c"
2225 break;
2226
2227 case 28:
2228 #line 293 "yyscript.y"
2229 { script_set_entry(closure, (yyvsp[-1].string).value, (yyvsp[-1].string).length); }
2230 #line 2231 "yyscript.c"
2231 break;
2232
2233 case 30:
2234 #line 296 "yyscript.y"
2235 { script_add_assertion(closure, (yyvsp[-3].expr), (yyvsp[-1].string).value, (yyvsp[-1].string).length); }
2236 #line 2237 "yyscript.c"
2237 break;
2238
2239 case 31:
2240 #line 298 "yyscript.y"
2241 { script_include_directive(PARSING_LINKER_SCRIPT, closure,
2242 (yyvsp[0].string).value, (yyvsp[0].string).length); }
2243 #line 2244 "yyscript.c"
2244 break;
2245
2246 case 35:
2247 #line 317 "yyscript.y"
2248 { script_push_lex_into_expression_mode(closure); }
2249 #line 2250 "yyscript.c"
2250 break;
2251
2252 case 36:
2253 #line 319 "yyscript.y"
2254 { script_pop_lex_mode(closure); }
2255 #line 2256 "yyscript.c"
2256 break;
2257
2258 case 37:
2259 #line 324 "yyscript.y"
2260 { script_add_extern(closure, (yyvsp[0].string).value, (yyvsp[0].string).length); }
2261 #line 2262 "yyscript.c"
2262 break;
2263
2264 case 38:
2265 #line 326 "yyscript.y"
2266 { script_add_extern(closure, (yyvsp[0].string).value, (yyvsp[0].string).length); }
2267 #line 2268 "yyscript.c"
2268 break;
2269
2270 case 39:
2271 #line 328 "yyscript.y"
2272 { script_add_extern(closure, (yyvsp[0].string).value, (yyvsp[0].string).length); }
2273 #line 2274 "yyscript.c"
2274 break;
2275
2276 case 42:
2277 #line 340 "yyscript.y"
2278 { script_add_file(closure, (yyvsp[0].string).value, (yyvsp[0].string).length); }
2279 #line 2280 "yyscript.c"
2280 break;
2281
2282 case 43:
2283 #line 342 "yyscript.y"
2284 { script_add_library(closure, (yyvsp[0].string).value, (yyvsp[0].string).length); }
2285 #line 2286 "yyscript.c"
2286 break;
2287
2288 case 44:
2289 #line 344 "yyscript.y"
2290 { script_start_as_needed(closure); }
2291 #line 2292 "yyscript.c"
2292 break;
2293
2294 case 45:
2295 #line 346 "yyscript.y"
2296 { script_end_as_needed(closure); }
2297 #line 2298 "yyscript.c"
2298 break;
2299
2300 case 48:
2301 #line 358 "yyscript.y"
2302 { script_set_entry(closure, (yyvsp[-1].string).value, (yyvsp[-1].string).length); }
2303 #line 2304 "yyscript.c"
2304 break;
2305
2306 case 50:
2307 #line 361 "yyscript.y"
2308 { script_add_assertion(closure, (yyvsp[-3].expr), (yyvsp[-1].string).value, (yyvsp[-1].string).length); }
2309 #line 2310 "yyscript.c"
2310 break;
2311
2312 case 51:
2313 #line 363 "yyscript.y"
2314 { script_include_directive(PARSING_SECTIONS_BLOCK, closure,
2315 (yyvsp[0].string).value, (yyvsp[0].string).length); }
2316 #line 2317 "yyscript.c"
2317 break;
2318
2319 case 52:
2320 #line 366 "yyscript.y"
2321 { script_start_output_section(closure, (yyvsp[-1].string).value, (yyvsp[-1].string).length, &(yyvsp[0].output_section_header)); }
2322 #line 2323 "yyscript.c"
2323 break;
2324
2325 case 53:
2326 #line 368 "yyscript.y"
2327 { script_finish_output_section(closure, &(yyvsp[0].output_section_trailer)); }
2328 #line 2329 "yyscript.c"
2329 break;
2330
2331 case 54:
2332 #line 374 "yyscript.y"
2333 { script_push_lex_into_expression_mode(closure); }
2334 #line 2335 "yyscript.c"
2335 break;
2336
2337 case 55:
2338 #line 376 "yyscript.y"
2339 { script_pop_lex_mode(closure); }
2340 #line 2341 "yyscript.c"
2341 break;
2342
2343 case 56:
2344 #line 378 "yyscript.y"
2345 {
2346 (yyval.output_section_header).address = (yyvsp[-5].output_section_header).address;
2347 (yyval.output_section_header).section_type = (yyvsp[-5].output_section_header).section_type;
2348 (yyval.output_section_header).load_address = (yyvsp[-4].expr);
2349 (yyval.output_section_header).align = (yyvsp[-3].expr);
2350 (yyval.output_section_header).subalign = (yyvsp[-2].expr);
2351 (yyval.output_section_header).constraint = (yyvsp[0].constraint);
2352 }
2353 #line 2354 "yyscript.c"
2354 break;
2355
2356 case 57:
2357 #line 394 "yyscript.y"
2358 {
2359 (yyval.output_section_header).address = NULL;
2360 (yyval.output_section_header).section_type = SCRIPT_SECTION_TYPE_NONE;
2361 }
2362 #line 2363 "yyscript.c"
2363 break;
2364
2365 case 58:
2366 #line 399 "yyscript.y"
2367 {
2368 (yyval.output_section_header).address = NULL;
2369 (yyval.output_section_header).section_type = SCRIPT_SECTION_TYPE_NONE;
2370 }
2371 #line 2372 "yyscript.c"
2372 break;
2373
2374 case 59:
2375 #line 404 "yyscript.y"
2376 {
2377 (yyval.output_section_header).address = (yyvsp[-1].expr);
2378 (yyval.output_section_header).section_type = SCRIPT_SECTION_TYPE_NONE;
2379 }
2380 #line 2381 "yyscript.c"
2381 break;
2382
2383 case 60:
2384 #line 409 "yyscript.y"
2385 {
2386 (yyval.output_section_header).address = (yyvsp[-3].expr);
2387 (yyval.output_section_header).section_type = SCRIPT_SECTION_TYPE_NONE;
2388 }
2389 #line 2390 "yyscript.c"
2390 break;
2391
2392 case 61:
2393 #line 414 "yyscript.y"
2394 {
2395 (yyval.output_section_header).address = NULL;
2396 (yyval.output_section_header).section_type = (yyvsp[-2].section_type);
2397 }
2398 #line 2399 "yyscript.c"
2399 break;
2400
2401 case 62:
2402 #line 419 "yyscript.y"
2403 {
2404 (yyval.output_section_header).address = (yyvsp[-4].expr);
2405 (yyval.output_section_header).section_type = (yyvsp[-2].section_type);
2406 }
2407 #line 2408 "yyscript.c"
2408 break;
2409
2410 case 63:
2411 #line 428 "yyscript.y"
2412 { (yyval.section_type) = SCRIPT_SECTION_TYPE_NOLOAD; }
2413 #line 2414 "yyscript.c"
2414 break;
2415
2416 case 64:
2417 #line 430 "yyscript.y"
2418 {
2419 yyerror(closure, "DSECT section type is unsupported");
2420 (yyval.section_type) = SCRIPT_SECTION_TYPE_DSECT;
2421 }
2422 #line 2423 "yyscript.c"
2423 break;
2424
2425 case 65:
2426 #line 435 "yyscript.y"
2427 {
2428 yyerror(closure, "COPY section type is unsupported");
2429 (yyval.section_type) = SCRIPT_SECTION_TYPE_COPY;
2430 }
2431 #line 2432 "yyscript.c"
2432 break;
2433
2434 case 66:
2435 #line 440 "yyscript.y"
2436 {
2437 yyerror(closure, "INFO section type is unsupported");
2438 (yyval.section_type) = SCRIPT_SECTION_TYPE_INFO;
2439 }
2440 #line 2441 "yyscript.c"
2441 break;
2442
2443 case 67:
2444 #line 445 "yyscript.y"
2445 {
2446 yyerror(closure, "OVERLAY section type is unsupported");
2447 (yyval.section_type) = SCRIPT_SECTION_TYPE_OVERLAY;
2448 }
2449 #line 2450 "yyscript.c"
2450 break;
2451
2452 case 68:
2453 #line 454 "yyscript.y"
2454 { (yyval.expr) = NULL; }
2455 #line 2456 "yyscript.c"
2456 break;
2457
2458 case 69:
2459 #line 456 "yyscript.y"
2460 { (yyval.expr) = (yyvsp[-1].expr); }
2461 #line 2462 "yyscript.c"
2462 break;
2463
2464 case 70:
2465 #line 462 "yyscript.y"
2466 { (yyval.expr) = NULL; }
2467 #line 2468 "yyscript.c"
2468 break;
2469
2470 case 71:
2471 #line 464 "yyscript.y"
2472 { (yyval.expr) = (yyvsp[-1].expr); }
2473 #line 2474 "yyscript.c"
2474 break;
2475
2476 case 72:
2477 #line 470 "yyscript.y"
2478 { (yyval.expr) = NULL; }
2479 #line 2480 "yyscript.c"
2480 break;
2481
2482 case 73:
2483 #line 472 "yyscript.y"
2484 { (yyval.expr) = (yyvsp[-1].expr); }
2485 #line 2486 "yyscript.c"
2486 break;
2487
2488 case 74:
2489 #line 478 "yyscript.y"
2490 { (yyval.constraint) = CONSTRAINT_NONE; }
2491 #line 2492 "yyscript.c"
2492 break;
2493
2494 case 75:
2495 #line 480 "yyscript.y"
2496 { (yyval.constraint) = CONSTRAINT_ONLY_IF_RO; }
2497 #line 2498 "yyscript.c"
2498 break;
2499
2500 case 76:
2501 #line 482 "yyscript.y"
2502 { (yyval.constraint) = CONSTRAINT_ONLY_IF_RW; }
2503 #line 2504 "yyscript.c"
2504 break;
2505
2506 case 77:
2507 #line 484 "yyscript.y"
2508 { (yyval.constraint) = CONSTRAINT_SPECIAL; }
2509 #line 2510 "yyscript.c"
2510 break;
2511
2512 case 78:
2513 #line 490 "yyscript.y"
2514 {
2515 (yyval.output_section_trailer).fill = (yyvsp[-1].expr);
2516 (yyval.output_section_trailer).phdrs = (yyvsp[-2].string_list);
2517 }
2518 #line 2519 "yyscript.c"
2519 break;
2520
2521 case 79:
2522 #line 499 "yyscript.y"
2523 { script_set_section_region(closure, (yyvsp[0].string).value, (yyvsp[0].string).length, 1); }
2524 #line 2525 "yyscript.c"
2525 break;
2526
2527 case 81:
2528 #line 506 "yyscript.y"
2529 { script_set_section_region(closure, (yyvsp[0].string).value, (yyvsp[0].string).length, 0); }
2530 #line 2531 "yyscript.c"
2531 break;
2532
2533 case 83:
2534 #line 513 "yyscript.y"
2535 { (yyval.string_list) = script_string_list_push_back((yyvsp[-2].string_list), (yyvsp[0].string).value, (yyvsp[0].string).length); }
2536 #line 2537 "yyscript.c"
2537 break;
2538
2539 case 84:
2540 #line 515 "yyscript.y"
2541 { (yyval.string_list) = NULL; }
2542 #line 2543 "yyscript.c"
2543 break;
2544
2545 case 85:
2546 #line 522 "yyscript.y"
2547 { (yyval.expr) = (yyvsp[0].expr); }
2548 #line 2549 "yyscript.c"
2549 break;
2550
2551 case 86:
2552 #line 524 "yyscript.y"
2553 { (yyval.expr) = NULL; }
2554 #line 2555 "yyscript.c"
2555 break;
2556
2557 case 91:
2558 #line 540 "yyscript.y"
2559 { script_add_data(closure, (yyvsp[-3].integer), (yyvsp[-1].expr)); }
2560 #line 2561 "yyscript.c"
2561 break;
2562
2563 case 92:
2564 #line 542 "yyscript.y"
2565 { script_add_assertion(closure, (yyvsp[-3].expr), (yyvsp[-1].string).value, (yyvsp[-1].string).length); }
2566 #line 2567 "yyscript.c"
2567 break;
2568
2569 case 93:
2570 #line 544 "yyscript.y"
2571 { script_add_fill(closure, (yyvsp[-1].expr)); }
2572 #line 2573 "yyscript.c"
2573 break;
2574
2575 case 94:
2576 #line 546 "yyscript.y"
2577 {
2578 /* The GNU linker uses CONSTRUCTORS for the a.out object
2579 file format. It does nothing when using ELF. Since
2580 some ELF linker scripts use it although it does
2581 nothing, we accept it and ignore it. */
2582 }
2583 #line 2584 "yyscript.c"
2584 break;
2585
2586 case 96:
2587 #line 554 "yyscript.y"
2588 { script_include_directive(PARSING_SECTION_COMMANDS, closure,
2589 (yyvsp[0].string).value, (yyvsp[0].string).length); }
2590 #line 2591 "yyscript.c"
2591 break;
2592
2593 case 98:
2594 #line 563 "yyscript.y"
2595 { (yyval.integer) = QUAD; }
2596 #line 2597 "yyscript.c"
2597 break;
2598
2599 case 99:
2600 #line 565 "yyscript.y"
2601 { (yyval.integer) = SQUAD; }
2602 #line 2603 "yyscript.c"
2603 break;
2604
2605 case 100:
2606 #line 567 "yyscript.y"
2607 { (yyval.integer) = LONG; }
2608 #line 2609 "yyscript.c"
2609 break;
2610
2611 case 101:
2612 #line 569 "yyscript.y"
2613 { (yyval.integer) = SHORT; }
2614 #line 2615 "yyscript.c"
2615 break;
2616
2617 case 102:
2618 #line 571 "yyscript.y"
2619 { (yyval.integer) = BYTE; }
2620 #line 2621 "yyscript.c"
2621 break;
2622
2623 case 103:
2624 #line 578 "yyscript.y"
2625 { script_add_input_section(closure, &(yyvsp[0].input_section_spec), 0); }
2626 #line 2627 "yyscript.c"
2627 break;
2628
2629 case 104:
2630 #line 580 "yyscript.y"
2631 { script_add_input_section(closure, &(yyvsp[-1].input_section_spec), 1); }
2632 #line 2633 "yyscript.c"
2633 break;
2634
2635 case 105:
2636 #line 586 "yyscript.y"
2637 {
2638 (yyval.input_section_spec).file.name = (yyvsp[0].string);
2639 (yyval.input_section_spec).file.sort = SORT_WILDCARD_NONE;
2640 (yyval.input_section_spec).input_sections.sections = NULL;
2641 (yyval.input_section_spec).input_sections.exclude = NULL;
2642 }
2643 #line 2644 "yyscript.c"
2644 break;
2645
2646 case 106:
2647 #line 593 "yyscript.y"
2648 {
2649 (yyval.input_section_spec).file = (yyvsp[-3].wildcard_section);
2650 (yyval.input_section_spec).input_sections = (yyvsp[-1].wildcard_sections);
2651 }
2652 #line 2653 "yyscript.c"
2653 break;
2654
2655 case 107:
2656 #line 602 "yyscript.y"
2657 {
2658 (yyval.wildcard_section).name = (yyvsp[0].string);
2659 (yyval.wildcard_section).sort = SORT_WILDCARD_NONE;
2660 }
2661 #line 2662 "yyscript.c"
2662 break;
2663
2664 case 108:
2665 #line 607 "yyscript.y"
2666 {
2667 (yyval.wildcard_section).name = (yyvsp[-1].string);
2668 (yyval.wildcard_section).sort = SORT_WILDCARD_BY_NAME;
2669 }
2670 #line 2671 "yyscript.c"
2671 break;
2672
2673 case 109:
2674 #line 616 "yyscript.y"
2675 {
2676 (yyval.wildcard_sections).sections = script_string_sort_list_add((yyvsp[-2].wildcard_sections).sections, &(yyvsp[0].wildcard_section));
2677 (yyval.wildcard_sections).exclude = (yyvsp[-2].wildcard_sections).exclude;
2678 }
2679 #line 2680 "yyscript.c"
2680 break;
2681
2682 case 110:
2683 #line 621 "yyscript.y"
2684 {
2685 (yyval.wildcard_sections).sections = script_new_string_sort_list(&(yyvsp[0].wildcard_section));
2686 (yyval.wildcard_sections).exclude = NULL;
2687 }
2688 #line 2689 "yyscript.c"
2689 break;
2690
2691 case 111:
2692 #line 626 "yyscript.y"
2693 {
2694 (yyval.wildcard_sections).sections = (yyvsp[-5].wildcard_sections).sections;
2695 (yyval.wildcard_sections).exclude = script_string_list_append((yyvsp[-5].wildcard_sections).exclude, (yyvsp[-1].string_list));
2696 }
2697 #line 2698 "yyscript.c"
2698 break;
2699
2700 case 112:
2701 #line 631 "yyscript.y"
2702 {
2703 (yyval.wildcard_sections).sections = NULL;
2704 (yyval.wildcard_sections).exclude = (yyvsp[-1].string_list);
2705 }
2706 #line 2707 "yyscript.c"
2707 break;
2708
2709 case 113:
2710 #line 640 "yyscript.y"
2711 {
2712 (yyval.wildcard_section).name = (yyvsp[0].string);
2713 (yyval.wildcard_section).sort = SORT_WILDCARD_NONE;
2714 }
2715 #line 2716 "yyscript.c"
2716 break;
2717
2718 case 114:
2719 #line 645 "yyscript.y"
2720 {
2721 (yyval.wildcard_section).name = (yyvsp[-1].wildcard_section).name;
2722 switch ((yyvsp[-1].wildcard_section).sort)
2723 {
2724 case SORT_WILDCARD_NONE:
2725 (yyval.wildcard_section).sort = SORT_WILDCARD_BY_NAME;
2726 break;
2727 case SORT_WILDCARD_BY_NAME:
2728 case SORT_WILDCARD_BY_NAME_BY_ALIGNMENT:
2729 break;
2730 case SORT_WILDCARD_BY_ALIGNMENT:
2731 case SORT_WILDCARD_BY_ALIGNMENT_BY_NAME:
2732 (yyval.wildcard_section).sort = SORT_WILDCARD_BY_NAME_BY_ALIGNMENT;
2733 break;
2734 default:
2735 abort();
2736 }
2737 }
2738 #line 2739 "yyscript.c"
2739 break;
2740
2741 case 115:
2742 #line 664 "yyscript.y"
2743 {
2744 (yyval.wildcard_section).name = (yyvsp[-1].wildcard_section).name;
2745 switch ((yyvsp[-1].wildcard_section).sort)
2746 {
2747 case SORT_WILDCARD_NONE:
2748 (yyval.wildcard_section).sort = SORT_WILDCARD_BY_ALIGNMENT;
2749 break;
2750 case SORT_WILDCARD_BY_ALIGNMENT:
2751 case SORT_WILDCARD_BY_ALIGNMENT_BY_NAME:
2752 break;
2753 case SORT_WILDCARD_BY_NAME:
2754 case SORT_WILDCARD_BY_NAME_BY_ALIGNMENT:
2755 (yyval.wildcard_section).sort = SORT_WILDCARD_BY_ALIGNMENT_BY_NAME;
2756 break;
2757 default:
2758 abort();
2759 }
2760 }
2761 #line 2762 "yyscript.c"
2762 break;
2763
2764 case 116:
2765 #line 683 "yyscript.y"
2766 {
2767 (yyval.wildcard_section).name = (yyvsp[-1].string);
2768 (yyval.wildcard_section).sort = SORT_WILDCARD_BY_INIT_PRIORITY;
2769 }
2770 #line 2771 "yyscript.c"
2771 break;
2772
2773 case 117:
2774 #line 692 "yyscript.y"
2775 { (yyval.string_list) = script_string_list_push_back((yyvsp[-2].string_list), (yyvsp[0].string).value, (yyvsp[0].string).length); }
2776 #line 2777 "yyscript.c"
2777 break;
2778
2779 case 118:
2780 #line 694 "yyscript.y"
2781 { (yyval.string_list) = script_new_string_list((yyvsp[0].string).value, (yyvsp[0].string).length); }
2782 #line 2783 "yyscript.c"
2783 break;
2784
2785 case 119:
2786 #line 701 "yyscript.y"
2787 { (yyval.string) = (yyvsp[0].string); }
2788 #line 2789 "yyscript.c"
2789 break;
2790
2791 case 120:
2792 #line 703 "yyscript.y"
2793 {
2794 (yyval.string).value = "*";
2795 (yyval.string).length = 1;
2796 }
2797 #line 2798 "yyscript.c"
2798 break;
2799
2800 case 121:
2801 #line 708 "yyscript.y"
2802 {
2803 (yyval.string).value = "?";
2804 (yyval.string).length = 1;
2805 }
2806 #line 2807 "yyscript.c"
2807 break;
2808
2809 case 124:
2810 #line 723 "yyscript.y"
2811 { script_add_memory(closure, (yyvsp[-9].string).value, (yyvsp[-9].string).length, (yyvsp[-8].integer), (yyvsp[-4].expr), (yyvsp[0].expr)); }
2812 #line 2813 "yyscript.c"
2813 break;
2814
2815 case 125:
2816 #line 726 "yyscript.y"
2817 { script_include_directive(PARSING_MEMORY_DEF, closure,
2818 (yyvsp[0].string).value, (yyvsp[0].string).length); }
2819 #line 2820 "yyscript.c"
2820 break;
2821
2822 case 127:
2823 #line 734 "yyscript.y"
2824 { (yyval.integer) = script_parse_memory_attr(closure, (yyvsp[-1].string).value, (yyvsp[-1].string).length, 0); }
2825 #line 2826 "yyscript.c"
2826 break;
2827
2828 case 128:
2829 #line 737 "yyscript.y"
2830 { (yyval.integer) = script_parse_memory_attr(closure, (yyvsp[-1].string).value, (yyvsp[-1].string).length, 1); }
2831 #line 2832 "yyscript.c"
2832 break;
2833
2834 case 129:
2835 #line 739 "yyscript.y"
2836 { (yyval.integer) = 0; }
2837 #line 2838 "yyscript.c"
2838 break;
2839
2840 case 138:
2841 #line 767 "yyscript.y"
2842 { script_add_phdr(closure, (yyvsp[-3].string).value, (yyvsp[-3].string).length, (yyvsp[-2].integer), &(yyvsp[-1].phdr_info)); }
2843 #line 2844 "yyscript.c"
2844 break;
2845
2846 case 139:
2847 #line 776 "yyscript.y"
2848 { (yyval.integer) = script_phdr_string_to_type(closure, (yyvsp[0].string).value, (yyvsp[0].string).length); }
2849 #line 2850 "yyscript.c"
2850 break;
2851
2852 case 140:
2853 #line 778 "yyscript.y"
2854 { (yyval.integer) = (yyvsp[0].integer); }
2855 #line 2856 "yyscript.c"
2856 break;
2857
2858 case 141:
2859 #line 784 "yyscript.y"
2860 { memset(&(yyval.phdr_info), 0, sizeof(struct Phdr_info)); }
2861 #line 2862 "yyscript.c"
2862 break;
2863
2864 case 142:
2865 #line 786 "yyscript.y"
2866 {
2867 (yyval.phdr_info) = (yyvsp[0].phdr_info);
2868 if ((yyvsp[-1].string).length == 7 && strncmp((yyvsp[-1].string).value, "FILEHDR", 7) == 0)
2869 (yyval.phdr_info).includes_filehdr = 1;
2870 else
2871 yyerror(closure, "PHDRS syntax error");
2872 }
2873 #line 2874 "yyscript.c"
2874 break;
2875
2876 case 143:
2877 #line 794 "yyscript.y"
2878 {
2879 (yyval.phdr_info) = (yyvsp[0].phdr_info);
2880 (yyval.phdr_info).includes_phdrs = 1;
2881 }
2882 #line 2883 "yyscript.c"
2883 break;
2884
2885 case 144:
2886 #line 799 "yyscript.y"
2887 {
2888 (yyval.phdr_info) = (yyvsp[0].phdr_info);
2889 if ((yyvsp[-4].string).length == 5 && strncmp((yyvsp[-4].string).value, "FLAGS", 5) == 0)
2890 {
2891 (yyval.phdr_info).is_flags_valid = 1;
2892 (yyval.phdr_info).flags = (yyvsp[-2].integer);
2893 }
2894 else
2895 yyerror(closure, "PHDRS syntax error");
2896 }
2897 #line 2898 "yyscript.c"
2898 break;
2899
2900 case 145:
2901 #line 810 "yyscript.y"
2902 {
2903 (yyval.phdr_info) = (yyvsp[0].phdr_info);
2904 (yyval.phdr_info).load_address = (yyvsp[-2].expr);
2905 }
2906 #line 2907 "yyscript.c"
2907 break;
2908
2909 case 146:
2910 #line 819 "yyscript.y"
2911 { script_set_symbol(closure, (yyvsp[-2].string).value, (yyvsp[-2].string).length, (yyvsp[0].expr), 0, 0); }
2912 #line 2913 "yyscript.c"
2913 break;
2914
2915 case 147:
2916 #line 821 "yyscript.y"
2917 {
2918 Expression_ptr s = script_exp_string((yyvsp[-2].string).value, (yyvsp[-2].string).length);
2919 Expression_ptr e = script_exp_binary_add(s, (yyvsp[0].expr));
2920 script_set_symbol(closure, (yyvsp[-2].string).value, (yyvsp[-2].string).length, e, 0, 0);
2921 }
2922 #line 2923 "yyscript.c"
2923 break;
2924
2925 case 148:
2926 #line 827 "yyscript.y"
2927 {
2928 Expression_ptr s = script_exp_string((yyvsp[-2].string).value, (yyvsp[-2].string).length);
2929 Expression_ptr e = script_exp_binary_sub(s, (yyvsp[0].expr));
2930 script_set_symbol(closure, (yyvsp[-2].string).value, (yyvsp[-2].string).length, e, 0, 0);
2931 }
2932 #line 2933 "yyscript.c"
2933 break;
2934
2935 case 149:
2936 #line 833 "yyscript.y"
2937 {
2938 Expression_ptr s = script_exp_string((yyvsp[-2].string).value, (yyvsp[-2].string).length);
2939 Expression_ptr e = script_exp_binary_mult(s, (yyvsp[0].expr));
2940 script_set_symbol(closure, (yyvsp[-2].string).value, (yyvsp[-2].string).length, e, 0, 0);
2941 }
2942 #line 2943 "yyscript.c"
2943 break;
2944
2945 case 150:
2946 #line 839 "yyscript.y"
2947 {
2948 Expression_ptr s = script_exp_string((yyvsp[-2].string).value, (yyvsp[-2].string).length);
2949 Expression_ptr e = script_exp_binary_div(s, (yyvsp[0].expr));
2950 script_set_symbol(closure, (yyvsp[-2].string).value, (yyvsp[-2].string).length, e, 0, 0);
2951 }
2952 #line 2953 "yyscript.c"
2953 break;
2954
2955 case 151:
2956 #line 845 "yyscript.y"
2957 {
2958 Expression_ptr s = script_exp_string((yyvsp[-2].string).value, (yyvsp[-2].string).length);
2959 Expression_ptr e = script_exp_binary_lshift(s, (yyvsp[0].expr));
2960 script_set_symbol(closure, (yyvsp[-2].string).value, (yyvsp[-2].string).length, e, 0, 0);
2961 }
2962 #line 2963 "yyscript.c"
2963 break;
2964
2965 case 152:
2966 #line 851 "yyscript.y"
2967 {
2968 Expression_ptr s = script_exp_string((yyvsp[-2].string).value, (yyvsp[-2].string).length);
2969 Expression_ptr e = script_exp_binary_rshift(s, (yyvsp[0].expr));
2970 script_set_symbol(closure, (yyvsp[-2].string).value, (yyvsp[-2].string).length, e, 0, 0);
2971 }
2972 #line 2973 "yyscript.c"
2973 break;
2974
2975 case 153:
2976 #line 857 "yyscript.y"
2977 {
2978 Expression_ptr s = script_exp_string((yyvsp[-2].string).value, (yyvsp[-2].string).length);
2979 Expression_ptr e = script_exp_binary_bitwise_and(s, (yyvsp[0].expr));
2980 script_set_symbol(closure, (yyvsp[-2].string).value, (yyvsp[-2].string).length, e, 0, 0);
2981 }
2982 #line 2983 "yyscript.c"
2983 break;
2984
2985 case 154:
2986 #line 863 "yyscript.y"
2987 {
2988 Expression_ptr s = script_exp_string((yyvsp[-2].string).value, (yyvsp[-2].string).length);
2989 Expression_ptr e = script_exp_binary_bitwise_or(s, (yyvsp[0].expr));
2990 script_set_symbol(closure, (yyvsp[-2].string).value, (yyvsp[-2].string).length, e, 0, 0);
2991 }
2992 #line 2993 "yyscript.c"
2993 break;
2994
2995 case 155:
2996 #line 869 "yyscript.y"
2997 { script_set_symbol(closure, (yyvsp[-3].string).value, (yyvsp[-3].string).length, (yyvsp[-1].expr), 0, 1); }
2998 #line 2999 "yyscript.c"
2999 break;
3000
3001 case 156:
3002 #line 871 "yyscript.y"
3003 { script_set_symbol(closure, (yyvsp[-3].string).value, (yyvsp[-3].string).length, (yyvsp[-1].expr), 1, 0); }
3004 #line 3005 "yyscript.c"
3005 break;
3006
3007 case 157:
3008 #line 873 "yyscript.y"
3009 { script_set_symbol(closure, (yyvsp[-3].string).value, (yyvsp[-3].string).length, (yyvsp[-1].expr), 1, 1); }
3010 #line 3011 "yyscript.c"
3011 break;
3012
3013 case 158:
3014 #line 878 "yyscript.y"
3015 { script_push_lex_into_expression_mode(closure); }
3016 #line 3017 "yyscript.c"
3017 break;
3018
3019 case 159:
3020 #line 880 "yyscript.y"
3021 {
3022 script_pop_lex_mode(closure);
3023 (yyval.expr) = (yyvsp[0].expr);
3024 }
3025 #line 3026 "yyscript.c"
3026 break;
3027
3028 case 160:
3029 #line 889 "yyscript.y"
3030 { (yyval.expr) = (yyvsp[-1].expr); }
3031 #line 3032 "yyscript.c"
3032 break;
3033
3034 case 161:
3035 #line 891 "yyscript.y"
3036 { (yyval.expr) = script_exp_unary_minus((yyvsp[0].expr)); }
3037 #line 3038 "yyscript.c"
3038 break;
3039
3040 case 162:
3041 #line 893 "yyscript.y"
3042 { (yyval.expr) = script_exp_unary_logical_not((yyvsp[0].expr)); }
3043 #line 3044 "yyscript.c"
3044 break;
3045
3046 case 163:
3047 #line 895 "yyscript.y"
3048 { (yyval.expr) = script_exp_unary_bitwise_not((yyvsp[0].expr)); }
3049 #line 3050 "yyscript.c"
3050 break;
3051
3052 case 164:
3053 #line 897 "yyscript.y"
3054 { (yyval.expr) = (yyvsp[0].expr); }
3055 #line 3056 "yyscript.c"
3056 break;
3057
3058 case 165:
3059 #line 899 "yyscript.y"
3060 { (yyval.expr) = script_exp_binary_mult((yyvsp[-2].expr), (yyvsp[0].expr)); }
3061 #line 3062 "yyscript.c"
3062 break;
3063
3064 case 166:
3065 #line 901 "yyscript.y"
3066 { (yyval.expr) = script_exp_binary_div((yyvsp[-2].expr), (yyvsp[0].expr)); }
3067 #line 3068 "yyscript.c"
3068 break;
3069
3070 case 167:
3071 #line 903 "yyscript.y"
3072 { (yyval.expr) = script_exp_binary_mod((yyvsp[-2].expr), (yyvsp[0].expr)); }
3073 #line 3074 "yyscript.c"
3074 break;
3075
3076 case 168:
3077 #line 905 "yyscript.y"
3078 { (yyval.expr) = script_exp_binary_add((yyvsp[-2].expr), (yyvsp[0].expr)); }
3079 #line 3080 "yyscript.c"
3080 break;
3081
3082 case 169:
3083 #line 907 "yyscript.y"
3084 { (yyval.expr) = script_exp_binary_sub((yyvsp[-2].expr), (yyvsp[0].expr)); }
3085 #line 3086 "yyscript.c"
3086 break;
3087
3088 case 170:
3089 #line 909 "yyscript.y"
3090 { (yyval.expr) = script_exp_binary_lshift((yyvsp[-2].expr), (yyvsp[0].expr)); }
3091 #line 3092 "yyscript.c"
3092 break;
3093
3094 case 171:
3095 #line 911 "yyscript.y"
3096 { (yyval.expr) = script_exp_binary_rshift((yyvsp[-2].expr), (yyvsp[0].expr)); }
3097 #line 3098 "yyscript.c"
3098 break;
3099
3100 case 172:
3101 #line 913 "yyscript.y"
3102 { (yyval.expr) = script_exp_binary_eq((yyvsp[-2].expr), (yyvsp[0].expr)); }
3103 #line 3104 "yyscript.c"
3104 break;
3105
3106 case 173:
3107 #line 915 "yyscript.y"
3108 { (yyval.expr) = script_exp_binary_ne((yyvsp[-2].expr), (yyvsp[0].expr)); }
3109 #line 3110 "yyscript.c"
3110 break;
3111
3112 case 174:
3113 #line 917 "yyscript.y"
3114 { (yyval.expr) = script_exp_binary_le((yyvsp[-2].expr), (yyvsp[0].expr)); }
3115 #line 3116 "yyscript.c"
3116 break;
3117
3118 case 175:
3119 #line 919 "yyscript.y"
3120 { (yyval.expr) = script_exp_binary_ge((yyvsp[-2].expr), (yyvsp[0].expr)); }
3121 #line 3122 "yyscript.c"
3122 break;
3123
3124 case 176:
3125 #line 921 "yyscript.y"
3126 { (yyval.expr) = script_exp_binary_lt((yyvsp[-2].expr), (yyvsp[0].expr)); }
3127 #line 3128 "yyscript.c"
3128 break;
3129
3130 case 177:
3131 #line 923 "yyscript.y"
3132 { (yyval.expr) = script_exp_binary_gt((yyvsp[-2].expr), (yyvsp[0].expr)); }
3133 #line 3134 "yyscript.c"
3134 break;
3135
3136 case 178:
3137 #line 925 "yyscript.y"
3138 { (yyval.expr) = script_exp_binary_bitwise_and((yyvsp[-2].expr), (yyvsp[0].expr)); }
3139 #line 3140 "yyscript.c"
3140 break;
3141
3142 case 179:
3143 #line 927 "yyscript.y"
3144 { (yyval.expr) = script_exp_binary_bitwise_xor((yyvsp[-2].expr), (yyvsp[0].expr)); }
3145 #line 3146 "yyscript.c"
3146 break;
3147
3148 case 180:
3149 #line 929 "yyscript.y"
3150 { (yyval.expr) = script_exp_binary_bitwise_or((yyvsp[-2].expr), (yyvsp[0].expr)); }
3151 #line 3152 "yyscript.c"
3152 break;
3153
3154 case 181:
3155 #line 931 "yyscript.y"
3156 { (yyval.expr) = script_exp_binary_logical_and((yyvsp[-2].expr), (yyvsp[0].expr)); }
3157 #line 3158 "yyscript.c"
3158 break;
3159
3160 case 182:
3161 #line 933 "yyscript.y"
3162 { (yyval.expr) = script_exp_binary_logical_or((yyvsp[-2].expr), (yyvsp[0].expr)); }
3163 #line 3164 "yyscript.c"
3164 break;
3165
3166 case 183:
3167 #line 935 "yyscript.y"
3168 { (yyval.expr) = script_exp_trinary_cond((yyvsp[-4].expr), (yyvsp[-2].expr), (yyvsp[0].expr)); }
3169 #line 3170 "yyscript.c"
3170 break;
3171
3172 case 184:
3173 #line 937 "yyscript.y"
3174 { (yyval.expr) = script_exp_integer((yyvsp[0].integer)); }
3175 #line 3176 "yyscript.c"
3176 break;
3177
3178 case 185:
3179 #line 939 "yyscript.y"
3180 { (yyval.expr) = script_symbol(closure, (yyvsp[0].string).value, (yyvsp[0].string).length); }
3181 #line 3182 "yyscript.c"
3182 break;
3183
3184 case 186:
3185 #line 941 "yyscript.y"
3186 { (yyval.expr) = script_exp_function_max((yyvsp[-3].expr), (yyvsp[-1].expr)); }
3187 #line 3188 "yyscript.c"
3188 break;
3189
3190 case 187:
3191 #line 943 "yyscript.y"
3192 { (yyval.expr) = script_exp_function_min((yyvsp[-3].expr), (yyvsp[-1].expr)); }
3193 #line 3194 "yyscript.c"
3194 break;
3195
3196 case 188:
3197 #line 945 "yyscript.y"
3198 { (yyval.expr) = script_exp_function_defined((yyvsp[-1].string).value, (yyvsp[-1].string).length); }
3199 #line 3200 "yyscript.c"
3200 break;
3201
3202 case 189:
3203 #line 947 "yyscript.y"
3204 { (yyval.expr) = script_exp_function_sizeof_headers(); }
3205 #line 3206 "yyscript.c"
3206 break;
3207
3208 case 190:
3209 #line 949 "yyscript.y"
3210 { (yyval.expr) = script_exp_function_alignof((yyvsp[-1].string).value, (yyvsp[-1].string).length); }
3211 #line 3212 "yyscript.c"
3212 break;
3213
3214 case 191:
3215 #line 951 "yyscript.y"
3216 { (yyval.expr) = script_exp_function_sizeof((yyvsp[-1].string).value, (yyvsp[-1].string).length); }
3217 #line 3218 "yyscript.c"
3218 break;
3219
3220 case 192:
3221 #line 953 "yyscript.y"
3222 { (yyval.expr) = script_exp_function_addr((yyvsp[-1].string).value, (yyvsp[-1].string).length); }
3223 #line 3224 "yyscript.c"
3224 break;
3225
3226 case 193:
3227 #line 955 "yyscript.y"
3228 { (yyval.expr) = script_exp_function_loadaddr((yyvsp[-1].string).value, (yyvsp[-1].string).length); }
3229 #line 3230 "yyscript.c"
3230 break;
3231
3232 case 194:
3233 #line 957 "yyscript.y"
3234 { (yyval.expr) = script_exp_function_origin(closure, (yyvsp[-1].string).value, (yyvsp[-1].string).length); }
3235 #line 3236 "yyscript.c"
3236 break;
3237
3238 case 195:
3239 #line 959 "yyscript.y"
3240 { (yyval.expr) = script_exp_function_length(closure, (yyvsp[-1].string).value, (yyvsp[-1].string).length); }
3241 #line 3242 "yyscript.c"
3242 break;
3243
3244 case 196:
3245 #line 961 "yyscript.y"
3246 { (yyval.expr) = script_exp_function_constant((yyvsp[-1].string).value, (yyvsp[-1].string).length); }
3247 #line 3248 "yyscript.c"
3248 break;
3249
3250 case 197:
3251 #line 963 "yyscript.y"
3252 { (yyval.expr) = script_exp_function_absolute((yyvsp[-1].expr)); }
3253 #line 3254 "yyscript.c"
3254 break;
3255
3256 case 198:
3257 #line 965 "yyscript.y"
3258 { (yyval.expr) = script_exp_function_align(script_exp_string(".", 1), (yyvsp[-1].expr)); }
3259 #line 3260 "yyscript.c"
3260 break;
3261
3262 case 199:
3263 #line 967 "yyscript.y"
3264 { (yyval.expr) = script_exp_function_align((yyvsp[-3].expr), (yyvsp[-1].expr)); }
3265 #line 3266 "yyscript.c"
3266 break;
3267
3268 case 200:
3269 #line 969 "yyscript.y"
3270 { (yyval.expr) = script_exp_function_align(script_exp_string(".", 1), (yyvsp[-1].expr)); }
3271 #line 3272 "yyscript.c"
3272 break;
3273
3274 case 201:
3275 #line 971 "yyscript.y"
3276 {
3277 script_data_segment_align(closure);
3278 (yyval.expr) = script_exp_function_data_segment_align((yyvsp[-3].expr), (yyvsp[-1].expr));
3279 }
3280 #line 3281 "yyscript.c"
3281 break;
3282
3283 case 202:
3284 #line 976 "yyscript.y"
3285 {
3286 script_data_segment_relro_end(closure);
3287 (yyval.expr) = script_exp_function_data_segment_relro_end((yyvsp[-3].expr), (yyvsp[-1].expr));
3288 }
3289 #line 3290 "yyscript.c"
3290 break;
3291
3292 case 203:
3293 #line 981 "yyscript.y"
3294 { (yyval.expr) = script_exp_function_data_segment_end((yyvsp[-1].expr)); }
3295 #line 3296 "yyscript.c"
3296 break;
3297
3298 case 204:
3299 #line 983 "yyscript.y"
3300 {
3301 (yyval.expr) = script_exp_function_segment_start((yyvsp[-3].string).value, (yyvsp[-3].string).length, (yyvsp[-1].expr));
3302 /* We need to take note of any SEGMENT_START expressions
3303 because they change the behaviour of -Ttext, -Tdata and
3304 -Tbss options. */
3305 script_saw_segment_start_expression(closure);
3306 }
3307 #line 3308 "yyscript.c"
3308 break;
3309
3310 case 205:
3311 #line 991 "yyscript.y"
3312 { (yyval.expr) = script_exp_function_assert((yyvsp[-3].expr), (yyvsp[-1].string).value, (yyvsp[-1].string).length); }
3313 #line 3314 "yyscript.c"
3314 break;
3315
3316 case 206:
3317 #line 997 "yyscript.y"
3318 { script_set_symbol(closure, (yyvsp[-2].string).value, (yyvsp[-2].string).length, (yyvsp[0].expr), 0, 0); }
3319 #line 3320 "yyscript.c"
3320 break;
3321
3322 case 210:
3323 #line 1015 "yyscript.y"
3324 { script_new_vers_node (closure, NULL, (yyvsp[-3].versyms)); }
3325 #line 3326 "yyscript.c"
3326 break;
3327
3328 case 214:
3329 #line 1030 "yyscript.y"
3330 {
3331 script_register_vers_node (closure, NULL, 0, (yyvsp[-2].versnode), NULL);
3332 }
3333 #line 3334 "yyscript.c"
3334 break;
3335
3336 case 215:
3337 #line 1034 "yyscript.y"
3338 {
3339 script_register_vers_node (closure, (yyvsp[-4].string).value, (yyvsp[-4].string).length, (yyvsp[-2].versnode),
3340 NULL);
3341 }
3342 #line 3343 "yyscript.c"
3343 break;
3344
3345 case 216:
3346 #line 1039 "yyscript.y"
3347 {
3348 script_register_vers_node (closure, (yyvsp[-5].string).value, (yyvsp[-5].string).length, (yyvsp[-3].versnode), (yyvsp[-1].deplist));
3349 }
3350 #line 3351 "yyscript.c"
3351 break;
3352
3353 case 217:
3354 #line 1046 "yyscript.y"
3355 {
3356 (yyval.deplist) = script_add_vers_depend (closure, NULL, (yyvsp[0].string).value, (yyvsp[0].string).length);
3357 }
3358 #line 3359 "yyscript.c"
3359 break;
3360
3361 case 218:
3362 #line 1050 "yyscript.y"
3363 {
3364 (yyval.deplist) = script_add_vers_depend (closure, (yyvsp[-1].deplist), (yyvsp[0].string).value, (yyvsp[0].string).length);
3365 }
3366 #line 3367 "yyscript.c"
3367 break;
3368
3369 case 219:
3370 #line 1057 "yyscript.y"
3371 { (yyval.versnode) = script_new_vers_node (closure, NULL, NULL); }
3372 #line 3373 "yyscript.c"
3373 break;
3374
3375 case 220:
3376 #line 1059 "yyscript.y"
3377 { (yyval.versnode) = script_new_vers_node (closure, (yyvsp[-1].versyms), NULL); }
3378 #line 3379 "yyscript.c"
3379 break;
3380
3381 case 221:
3382 #line 1061 "yyscript.y"
3383 { (yyval.versnode) = script_new_vers_node (closure, (yyvsp[-1].versyms), NULL); }
3384 #line 3385 "yyscript.c"
3385 break;
3386
3387 case 222:
3388 #line 1063 "yyscript.y"
3389 { (yyval.versnode) = script_new_vers_node (closure, NULL, (yyvsp[-1].versyms)); }
3390 #line 3391 "yyscript.c"
3391 break;
3392
3393 case 223:
3394 #line 1065 "yyscript.y"
3395 { (yyval.versnode) = script_new_vers_node (closure, (yyvsp[-5].versyms), (yyvsp[-1].versyms)); }
3396 #line 3397 "yyscript.c"
3397 break;
3398
3399 case 224:
3400 #line 1074 "yyscript.y"
3401 {
3402 (yyval.versyms) = script_new_vers_pattern (closure, NULL, (yyvsp[0].string).value,
3403 (yyvsp[0].string).length, 0);
3404 }
3405 #line 3406 "yyscript.c"
3406 break;
3407
3408 case 225:
3409 #line 1079 "yyscript.y"
3410 {
3411 (yyval.versyms) = script_new_vers_pattern (closure, NULL, (yyvsp[0].string).value,
3412 (yyvsp[0].string).length, 1);
3413 }
3414 #line 3415 "yyscript.c"
3415 break;
3416
3417 case 226:
3418 #line 1084 "yyscript.y"
3419 {
3420 (yyval.versyms) = script_new_vers_pattern (closure, (yyvsp[-2].versyms), (yyvsp[0].string).value,
3421 (yyvsp[0].string).length, 0);
3422 }
3423 #line 3424 "yyscript.c"
3424 break;
3425
3426 case 227:
3427 #line 1089 "yyscript.y"
3428 {
3429 (yyval.versyms) = script_new_vers_pattern (closure, (yyvsp[-2].versyms), (yyvsp[0].string).value,
3430 (yyvsp[0].string).length, 1);
3431 }
3432 #line 3433 "yyscript.c"
3433 break;
3434
3435 case 228:
3436 #line 1095 "yyscript.y"
3437 { version_script_push_lang (closure, (yyvsp[-1].string).value, (yyvsp[-1].string).length); }
3438 #line 3439 "yyscript.c"
3439 break;
3440
3441 case 229:
3442 #line 1097 "yyscript.y"
3443 {
3444 (yyval.versyms) = (yyvsp[-2].versyms);
3445 version_script_pop_lang(closure);
3446 }
3447 #line 3448 "yyscript.c"
3448 break;
3449
3450 case 230:
3451 #line 1105 "yyscript.y"
3452 { version_script_push_lang (closure, (yyvsp[-1].string).value, (yyvsp[-1].string).length); }
3453 #line 3454 "yyscript.c"
3454 break;
3455
3456 case 231:
3457 #line 1107 "yyscript.y"
3458 {
3459 (yyval.versyms) = script_merge_expressions ((yyvsp[-8].versyms), (yyvsp[-2].versyms));
3460 version_script_pop_lang(closure);
3461 }
3462 #line 3463 "yyscript.c"
3463 break;
3464
3465 case 232:
3466 #line 1112 "yyscript.y"
3467 {
3468 (yyval.versyms) = script_new_vers_pattern (closure, NULL, "extern",
3469 sizeof("extern") - 1, 1);
3470 }
3471 #line 3472 "yyscript.c"
3472 break;
3473
3474 case 233:
3475 #line 1117 "yyscript.y"
3476 {
3477 (yyval.versyms) = script_new_vers_pattern (closure, (yyvsp[-2].versyms), "extern",
3478 sizeof("extern") - 1, 1);
3479 }
3480 #line 3481 "yyscript.c"
3481 break;
3482
3483 case 234:
3484 #line 1127 "yyscript.y"
3485 { (yyval.string) = (yyvsp[0].string); }
3486 #line 3487 "yyscript.c"
3487 break;
3488
3489 case 235:
3490 #line 1129 "yyscript.y"
3491 { (yyval.string) = (yyvsp[0].string); }
3492 #line 3493 "yyscript.c"
3493 break;
3494
3495
3496 #line 3497 "yyscript.c"
3497
3498 default: break;
3499 }
3500 /* User semantic actions sometimes alter yychar, and that requires
3501 that yytoken be updated with the new translation. We take the
3502 approach of translating immediately before every use of yytoken.
3503 One alternative is translating here after every semantic action,
3504 but that translation would be missed if the semantic action invokes
3505 YYABORT, YYACCEPT, or YYERROR immediately after altering yychar or
3506 if it invokes YYBACKUP. In the case of YYABORT or YYACCEPT, an
3507 incorrect destructor might then be invoked immediately. In the
3508 case of YYERROR or YYBACKUP, subsequent parser actions might lead
3509 to an incorrect destructor call or verbose syntax error message
3510 before the lookahead is translated. */
3511 YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc);
3512
3513 YYPOPSTACK (yylen);
3514 yylen = 0;
3515 YY_STACK_PRINT (yyss, yyssp);
3516
3517 *++yyvsp = yyval;
3518
3519 /* Now 'shift' the result of the reduction. Determine what state
3520 that goes to, based on the state we popped back to and the rule
3521 number reduced by. */
3522 {
3523 const int yylhs = yyr1[yyn] - YYNTOKENS;
3524 const int yyi = yypgoto[yylhs] + *yyssp;
3525 yystate = (0 <= yyi && yyi <= YYLAST && yycheck[yyi] == *yyssp
3526 ? yytable[yyi]
3527 : yydefgoto[yylhs]);
3528 }
3529
3530 goto yynewstate;
3531
3532
3533 /*--------------------------------------.
3534 | yyerrlab -- here on detecting error. |
3535 `--------------------------------------*/
3536 yyerrlab:
3537 /* Make sure we have latest lookahead translation. See comments at
3538 user semantic actions for why this is necessary. */
3539 yytoken = yychar == YYEMPTY ? YYEMPTY : YYTRANSLATE (yychar);
3540
3541 /* If not already recovering from an error, report this error. */
3542 if (!yyerrstatus)
3543 {
3544 ++yynerrs;
3545 #if ! YYERROR_VERBOSE
3546 yyerror (closure, YY_("syntax error"));
3547 #else
3548 # define YYSYNTAX_ERROR yysyntax_error (&yymsg_alloc, &yymsg, \
3549 yyssp, yytoken)
3550 {
3551 char const *yymsgp = YY_("syntax error");
3552 int yysyntax_error_status;
3553 yysyntax_error_status = YYSYNTAX_ERROR;
3554 if (yysyntax_error_status == 0)
3555 yymsgp = yymsg;
3556 else if (yysyntax_error_status == 1)
3557 {
3558 if (yymsg != yymsgbuf)
3559 YYSTACK_FREE (yymsg);
3560 yymsg = YY_CAST (char *, YYSTACK_ALLOC (YY_CAST (YYSIZE_T, yymsg_alloc)));
3561 if (!yymsg)
3562 {
3563 yymsg = yymsgbuf;
3564 yymsg_alloc = sizeof yymsgbuf;
3565 yysyntax_error_status = 2;
3566 }
3567 else
3568 {
3569 yysyntax_error_status = YYSYNTAX_ERROR;
3570 yymsgp = yymsg;
3571 }
3572 }
3573 yyerror (closure, yymsgp);
3574 if (yysyntax_error_status == 2)
3575 goto yyexhaustedlab;
3576 }
3577 # undef YYSYNTAX_ERROR
3578 #endif
3579 }
3580
3581
3582
3583 if (yyerrstatus == 3)
3584 {
3585 /* If just tried and failed to reuse lookahead token after an
3586 error, discard it. */
3587
3588 if (yychar <= YYEOF)
3589 {
3590 /* Return failure if at end of input. */
3591 if (yychar == YYEOF)
3592 YYABORT;
3593 }
3594 else
3595 {
3596 yydestruct ("Error: discarding",
3597 yytoken, &yylval, closure);
3598 yychar = YYEMPTY;
3599 }
3600 }
3601
3602 /* Else will try to reuse lookahead token after shifting the error
3603 token. */
3604 goto yyerrlab1;
3605
3606
3607 /*---------------------------------------------------.
3608 | yyerrorlab -- error raised explicitly by YYERROR. |
3609 `---------------------------------------------------*/
3610 yyerrorlab:
3611 /* Pacify compilers when the user code never invokes YYERROR and the
3612 label yyerrorlab therefore never appears in user code. */
3613 if (0)
3614 YYERROR;
3615
3616 /* Do not reclaim the symbols of the rule whose action triggered
3617 this YYERROR. */
3618 YYPOPSTACK (yylen);
3619 yylen = 0;
3620 YY_STACK_PRINT (yyss, yyssp);
3621 yystate = *yyssp;
3622 goto yyerrlab1;
3623
3624
3625 /*-------------------------------------------------------------.
3626 | yyerrlab1 -- common code for both syntax error and YYERROR. |
3627 `-------------------------------------------------------------*/
3628 yyerrlab1:
3629 yyerrstatus = 3; /* Each real token shifted decrements this. */
3630
3631 for (;;)
3632 {
3633 yyn = yypact[yystate];
3634 if (!yypact_value_is_default (yyn))
3635 {
3636 yyn += YYTERROR;
3637 if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYTERROR)
3638 {
3639 yyn = yytable[yyn];
3640 if (0 < yyn)
3641 break;
3642 }
3643 }
3644
3645 /* Pop the current state because it cannot handle the error token. */
3646 if (yyssp == yyss)
3647 YYABORT;
3648
3649
3650 yydestruct ("Error: popping",
3651 yystos[yystate], yyvsp, closure);
3652 YYPOPSTACK (1);
3653 yystate = *yyssp;
3654 YY_STACK_PRINT (yyss, yyssp);
3655 }
3656
3657 YY_IGNORE_MAYBE_UNINITIALIZED_BEGIN
3658 *++yyvsp = yylval;
3659 YY_IGNORE_MAYBE_UNINITIALIZED_END
3660
3661
3662 /* Shift the error token. */
3663 YY_SYMBOL_PRINT ("Shifting", yystos[yyn], yyvsp, yylsp);
3664
3665 yystate = yyn;
3666 goto yynewstate;
3667
3668
3669 /*-------------------------------------.
3670 | yyacceptlab -- YYACCEPT comes here. |
3671 `-------------------------------------*/
3672 yyacceptlab:
3673 yyresult = 0;
3674 goto yyreturn;
3675
3676
3677 /*-----------------------------------.
3678 | yyabortlab -- YYABORT comes here. |
3679 `-----------------------------------*/
3680 yyabortlab:
3681 yyresult = 1;
3682 goto yyreturn;
3683
3684
3685 #if !defined yyoverflow || YYERROR_VERBOSE
3686 /*-------------------------------------------------.
3687 | yyexhaustedlab -- memory exhaustion comes here. |
3688 `-------------------------------------------------*/
3689 yyexhaustedlab:
3690 yyerror (closure, YY_("memory exhausted"));
3691 yyresult = 2;
3692 /* Fall through. */
3693 #endif
3694
3695
3696 /*-----------------------------------------------------.
3697 | yyreturn -- parsing is finished, return the result. |
3698 `-----------------------------------------------------*/
3699 yyreturn:
3700 if (yychar != YYEMPTY)
3701 {
3702 /* Make sure we have latest lookahead translation. See comments at
3703 user semantic actions for why this is necessary. */
3704 yytoken = YYTRANSLATE (yychar);
3705 yydestruct ("Cleanup: discarding lookahead",
3706 yytoken, &yylval, closure);
3707 }
3708 /* Do not reclaim the symbols of the rule whose action triggered
3709 this YYABORT or YYACCEPT. */
3710 YYPOPSTACK (yylen);
3711 YY_STACK_PRINT (yyss, yyssp);
3712 while (yyssp != yyss)
3713 {
3714 yydestruct ("Cleanup: popping",
3715 yystos[*yyssp], yyvsp, closure);
3716 YYPOPSTACK (1);
3717 }
3718 #ifndef yyoverflow
3719 if (yyss != yyssa)
3720 YYSTACK_FREE (yyss);
3721 #endif
3722 #if YYERROR_VERBOSE
3723 if (yymsg != yymsgbuf)
3724 YYSTACK_FREE (yymsg);
3725 #endif
3726 return yyresult;
3727 }
3728 #line 1151 "yyscript.y"
3729
3730