OpenCores
URL https://opencores.org/ocsvn/openrisc_me/openrisc_me/trunk

Subversion Repositories openrisc_me

[/] [openrisc/] [trunk/] [gnu-src/] [binutils-2.20.1/] [binutils/] [defparse.c] - Blame information for rev 297

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 205 julius
/* A Bison parser, made by GNU Bison 2.3.  */
2
 
3
/* Skeleton implementation for Bison's Yacc-like parsers in C
4
 
5
   Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006
6
   Free Software Foundation, 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 2, or (at your option)
11
   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, write to the Free Software
20
   Foundation, Inc., 51 Franklin Street, Fifth Floor,
21
   Boston, MA 02110-1301, USA.  */
22
 
23
/* As a special exception, you may create a larger work that contains
24
   part or all of the Bison parser skeleton and distribute that work
25
   under terms of your choice, so long as that work isn't itself a
26
   parser generator using the skeleton or a modified version thereof
27
   as a parser skeleton.  Alternatively, if you modify or redistribute
28
   the parser skeleton itself, you may (at your option) remove this
29
   special exception, which will cause the skeleton and the resulting
30
   Bison output files to be licensed under the GNU General Public
31
   License without this special exception.
32
 
33
   This special exception was added by the Free Software Foundation in
34
   version 2.2 of Bison.  */
35
 
36
/* C LALR(1) parser skeleton written by Richard Stallman, by
37
   simplifying the original so-called "semantic" parser.  */
38
 
39
/* All symbols defined below should begin with yy or YY, to avoid
40
   infringing on user name space.  This should be done even for local
41
   variables, as they might otherwise be expanded by user macros.
42
   There are some unavoidable exceptions within include files to
43
   define necessary library symbols; they are noted "INFRINGES ON
44
   USER NAME SPACE" below.  */
45
 
46
/* Identify Bison output.  */
47
#define YYBISON 1
48
 
49
/* Bison version.  */
50
#define YYBISON_VERSION "2.3"
51
 
52
/* Skeleton name.  */
53
#define YYSKELETON_NAME "yacc.c"
54
 
55
/* Pure parsers.  */
56
#define YYPURE 0
57
 
58
/* Using locations.  */
59
#define YYLSP_NEEDED 0
60
 
61
 
62
 
63
/* Tokens.  */
64
#ifndef YYTOKENTYPE
65
# define YYTOKENTYPE
66
   /* Put the tokens into the symbol table, so that GDB and other debuggers
67
      know about them.  */
68
   enum yytokentype {
69
     NAME = 258,
70
     LIBRARY = 259,
71
     DESCRIPTION = 260,
72
     STACKSIZE = 261,
73
     HEAPSIZE = 262,
74
     CODE = 263,
75
     DATA = 264,
76
     SECTIONS = 265,
77
     EXPORTS = 266,
78
     IMPORTS = 267,
79
     VERSIONK = 268,
80
     BASE = 269,
81
     CONSTANT = 270,
82
     READ = 271,
83
     WRITE = 272,
84
     EXECUTE = 273,
85
     SHARED = 274,
86
     NONSHARED = 275,
87
     NONAME = 276,
88
     PRIVATE = 277,
89
     SINGLE = 278,
90
     MULTIPLE = 279,
91
     INITINSTANCE = 280,
92
     INITGLOBAL = 281,
93
     TERMINSTANCE = 282,
94
     TERMGLOBAL = 283,
95
     ID = 284,
96
     NUMBER = 285
97
   };
98
#endif
99
/* Tokens.  */
100
#define NAME 258
101
#define LIBRARY 259
102
#define DESCRIPTION 260
103
#define STACKSIZE 261
104
#define HEAPSIZE 262
105
#define CODE 263
106
#define DATA 264
107
#define SECTIONS 265
108
#define EXPORTS 266
109
#define IMPORTS 267
110
#define VERSIONK 268
111
#define BASE 269
112
#define CONSTANT 270
113
#define READ 271
114
#define WRITE 272
115
#define EXECUTE 273
116
#define SHARED 274
117
#define NONSHARED 275
118
#define NONAME 276
119
#define PRIVATE 277
120
#define SINGLE 278
121
#define MULTIPLE 279
122
#define INITINSTANCE 280
123
#define INITGLOBAL 281
124
#define TERMINSTANCE 282
125
#define TERMGLOBAL 283
126
#define ID 284
127
#define NUMBER 285
128
 
129
 
130
 
131
 
132
/* Copy the first part of user declarations.  */
133
#line 1 "defparse.y"
134
 /* defparse.y - parser for .def files */
135
 
136
/* Copyright 1995, 1997, 1998, 1999, 2001, 2004, 2005, 2007
137
   Free Software Foundation, Inc.
138
 
139
   This file is part of GNU Binutils.
140
 
141
   This program is free software; you can redistribute it and/or modify
142
   it under the terms of the GNU General Public License as published by
143
   the Free Software Foundation; either version 3 of the License, or
144
   (at your option) any later version.
145
 
146
   This program is distributed in the hope that it will be useful,
147
   but WITHOUT ANY WARRANTY; without even the implied warranty of
148
   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
149
   GNU General Public License for more details.
150
 
151
   You should have received a copy of the GNU General Public License
152
   along with this program; if not, write to the Free Software
153
   Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston,
154
   MA 02110-1301, USA.  */
155
 
156
#include "sysdep.h"
157
#include "bfd.h"
158
#include "libiberty.h"
159
#include "dlltool.h"
160
 
161
 
162
/* Enabling traces.  */
163
#ifndef YYDEBUG
164
# define YYDEBUG 0
165
#endif
166
 
167
/* Enabling verbose error messages.  */
168
#ifdef YYERROR_VERBOSE
169
# undef YYERROR_VERBOSE
170
# define YYERROR_VERBOSE 1
171
#else
172
# define YYERROR_VERBOSE 0
173
#endif
174
 
175
/* Enabling the token table.  */
176
#ifndef YYTOKEN_TABLE
177
# define YYTOKEN_TABLE 0
178
#endif
179
 
180
#if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED
181
typedef union YYSTYPE
182
#line 29 "defparse.y"
183
{
184
  char *id;
185
  int number;
186
}
187
/* Line 193 of yacc.c.  */
188
#line 189 "defparse.c"
189
        YYSTYPE;
190
# define yystype YYSTYPE /* obsolescent; will be withdrawn */
191
# define YYSTYPE_IS_DECLARED 1
192
# define YYSTYPE_IS_TRIVIAL 1
193
#endif
194
 
195
 
196
 
197
/* Copy the second part of user declarations.  */
198
 
199
 
200
/* Line 216 of yacc.c.  */
201
#line 202 "defparse.c"
202
 
203
#ifdef short
204
# undef short
205
#endif
206
 
207
#ifdef YYTYPE_UINT8
208
typedef YYTYPE_UINT8 yytype_uint8;
209
#else
210
typedef unsigned char yytype_uint8;
211
#endif
212
 
213
#ifdef YYTYPE_INT8
214
typedef YYTYPE_INT8 yytype_int8;
215
#elif (defined __STDC__ || defined __C99__FUNC__ \
216
     || defined __cplusplus || defined _MSC_VER)
217
typedef signed char yytype_int8;
218
#else
219
typedef short int yytype_int8;
220
#endif
221
 
222
#ifdef YYTYPE_UINT16
223
typedef YYTYPE_UINT16 yytype_uint16;
224
#else
225
typedef unsigned short int yytype_uint16;
226
#endif
227
 
228
#ifdef YYTYPE_INT16
229
typedef YYTYPE_INT16 yytype_int16;
230
#else
231
typedef short int yytype_int16;
232
#endif
233
 
234
#ifndef YYSIZE_T
235
# ifdef __SIZE_TYPE__
236
#  define YYSIZE_T __SIZE_TYPE__
237
# elif defined size_t
238
#  define YYSIZE_T size_t
239
# elif ! defined YYSIZE_T && (defined __STDC__ || defined __C99__FUNC__ \
240
     || defined __cplusplus || defined _MSC_VER)
241
#  include <stddef.h> /* INFRINGES ON USER NAME SPACE */
242
#  define YYSIZE_T size_t
243
# else
244
#  define YYSIZE_T unsigned int
245
# endif
246
#endif
247
 
248
#define YYSIZE_MAXIMUM ((YYSIZE_T) -1)
249
 
250
#ifndef YY_
251
# if defined YYENABLE_NLS && YYENABLE_NLS
252
#  if ENABLE_NLS
253
#   include <libintl.h> /* INFRINGES ON USER NAME SPACE */
254
#   define YY_(msgid) dgettext ("bison-runtime", msgid)
255
#  endif
256
# endif
257
# ifndef YY_
258
#  define YY_(msgid) msgid
259
# endif
260
#endif
261
 
262
/* Suppress unused-variable warnings by "using" E.  */
263
#if ! defined lint || defined __GNUC__
264
# define YYUSE(e) ((void) (e))
265
#else
266
# define YYUSE(e) /* empty */
267
#endif
268
 
269
/* Identity function, used to suppress warnings about constant conditions.  */
270
#ifndef lint
271
# define YYID(n) (n)
272
#else
273
#if (defined __STDC__ || defined __C99__FUNC__ \
274
     || defined __cplusplus || defined _MSC_VER)
275
static int
276
YYID (int i)
277
#else
278
static int
279
YYID (i)
280
    int i;
281
#endif
282
{
283
  return i;
284
}
285
#endif
286
 
287
#if ! defined yyoverflow || YYERROR_VERBOSE
288
 
289
/* The parser invokes alloca or malloc; define the necessary symbols.  */
290
 
291
# ifdef YYSTACK_USE_ALLOCA
292
#  if YYSTACK_USE_ALLOCA
293
#   ifdef __GNUC__
294
#    define YYSTACK_ALLOC __builtin_alloca
295
#   elif defined __BUILTIN_VA_ARG_INCR
296
#    include <alloca.h> /* INFRINGES ON USER NAME SPACE */
297
#   elif defined _AIX
298
#    define YYSTACK_ALLOC __alloca
299
#   elif defined _MSC_VER
300
#    include <malloc.h> /* INFRINGES ON USER NAME SPACE */
301
#    define alloca _alloca
302
#   else
303
#    define YYSTACK_ALLOC alloca
304
#    if ! defined _ALLOCA_H && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \
305
     || defined __cplusplus || defined _MSC_VER)
306
#     include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
307
#     ifndef _STDLIB_H
308
#      define _STDLIB_H 1
309
#     endif
310
#    endif
311
#   endif
312
#  endif
313
# endif
314
 
315
# ifdef YYSTACK_ALLOC
316
   /* Pacify GCC's `empty if-body' warning.  */
317
#  define YYSTACK_FREE(Ptr) do { /* empty */; } while (YYID (0))
318
#  ifndef YYSTACK_ALLOC_MAXIMUM
319
    /* The OS might guarantee only one guard page at the bottom of the stack,
320
       and a page size can be as small as 4096 bytes.  So we cannot safely
321
       invoke alloca (N) if N exceeds 4096.  Use a slightly smaller number
322
       to allow for a few compiler-allocated temporary stack slots.  */
323
#   define YYSTACK_ALLOC_MAXIMUM 4032 /* reasonable circa 2006 */
324
#  endif
325
# else
326
#  define YYSTACK_ALLOC YYMALLOC
327
#  define YYSTACK_FREE YYFREE
328
#  ifndef YYSTACK_ALLOC_MAXIMUM
329
#   define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM
330
#  endif
331
#  if (defined __cplusplus && ! defined _STDLIB_H \
332
       && ! ((defined YYMALLOC || defined malloc) \
333
             && (defined YYFREE || defined free)))
334
#   include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
335
#   ifndef _STDLIB_H
336
#    define _STDLIB_H 1
337
#   endif
338
#  endif
339
#  ifndef YYMALLOC
340
#   define YYMALLOC malloc
341
#   if ! defined malloc && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \
342
     || defined __cplusplus || defined _MSC_VER)
343
void *malloc (YYSIZE_T); /* INFRINGES ON USER NAME SPACE */
344
#   endif
345
#  endif
346
#  ifndef YYFREE
347
#   define YYFREE free
348
#   if ! defined free && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \
349
     || defined __cplusplus || defined _MSC_VER)
350
void free (void *); /* INFRINGES ON USER NAME SPACE */
351
#   endif
352
#  endif
353
# endif
354
#endif /* ! defined yyoverflow || YYERROR_VERBOSE */
355
 
356
 
357
#if (! defined yyoverflow \
358
     && (! defined __cplusplus \
359
         || (defined YYSTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL)))
360
 
361
/* A type that is properly aligned for any stack member.  */
362
union yyalloc
363
{
364
  yytype_int16 yyss;
365
  YYSTYPE yyvs;
366
  };
367
 
368
/* The size of the maximum gap between one aligned stack and the next.  */
369
# define YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1)
370
 
371
/* The size of an array large to enough to hold all stacks, each with
372
   N elements.  */
373
# define YYSTACK_BYTES(N) \
374
     ((N) * (sizeof (yytype_int16) + sizeof (YYSTYPE)) \
375
      + YYSTACK_GAP_MAXIMUM)
376
 
377
/* Copy COUNT objects from FROM to TO.  The source and destination do
378
   not overlap.  */
379
# ifndef YYCOPY
380
#  if defined __GNUC__ && 1 < __GNUC__
381
#   define YYCOPY(To, From, Count) \
382
      __builtin_memcpy (To, From, (Count) * sizeof (*(From)))
383
#  else
384
#   define YYCOPY(To, From, Count)              \
385
      do                                        \
386
        {                                       \
387
          YYSIZE_T yyi;                         \
388
          for (yyi = 0; yyi < (Count); yyi++)    \
389
            (To)[yyi] = (From)[yyi];            \
390
        }                                       \
391
      while (YYID (0))
392
#  endif
393
# endif
394
 
395
/* Relocate STACK from its old location to the new one.  The
396
   local variables YYSIZE and YYSTACKSIZE give the old and new number of
397
   elements in the stack, and YYPTR gives the new location of the
398
   stack.  Advance YYPTR to a properly aligned location for the next
399
   stack.  */
400
# define YYSTACK_RELOCATE(Stack)                                        \
401
    do                                                                  \
402
      {                                                                 \
403
        YYSIZE_T yynewbytes;                                            \
404
        YYCOPY (&yyptr->Stack, Stack, yysize);                          \
405
        Stack = &yyptr->Stack;                                          \
406
        yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \
407
        yyptr += yynewbytes / sizeof (*yyptr);                          \
408
      }                                                                 \
409
    while (YYID (0))
410
 
411
#endif
412
 
413
/* YYFINAL -- State number of the termination state.  */
414
#define YYFINAL  38
415
/* YYLAST -- Last index in YYTABLE.  */
416
#define YYLAST   114
417
 
418
/* YYNTOKENS -- Number of terminals.  */
419
#define YYNTOKENS  35
420
/* YYNNTS -- Number of nonterminals.  */
421
#define YYNNTS  23
422
/* YYNRULES -- Number of rules.  */
423
#define YYNRULES  68
424
/* YYNRULES -- Number of states.  */
425
#define YYNSTATES  98
426
 
427
/* YYTRANSLATE(YYLEX) -- Bison symbol number corresponding to YYLEX.  */
428
#define YYUNDEFTOK  2
429
#define YYMAXUTOK   285
430
 
431
#define YYTRANSLATE(YYX)                                                \
432
  ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK)
433
 
434
/* YYTRANSLATE[YYLEX] -- Bison symbol number corresponding to YYLEX.  */
435
static const yytype_uint8 yytranslate[] =
436
{
437
       0,     2,     2,     2,     2,     2,     2,     2,     2,     2,
438
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
439
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
440
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
441
       2,     2,     2,     2,    33,     2,    31,     2,     2,     2,
442
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
443
       2,    32,     2,     2,    34,     2,     2,     2,     2,     2,
444
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
445
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
446
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
447
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
448
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
449
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
450
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
451
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
452
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
453
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
454
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
455
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
456
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
457
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
458
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
459
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
460
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
461
       2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
462
       2,     2,     2,     2,     2,     2,     1,     2,     3,     4,
463
       5,     6,     7,     8,     9,    10,    11,    12,    13,    14,
464
      15,    16,    17,    18,    19,    20,    21,    22,    23,    24,
465
      25,    26,    27,    28,    29,    30
466
};
467
 
468
#if YYDEBUG
469
/* YYPRHS[YYN] -- Index of the first RHS symbol of rule number YYN in
470
   YYRHS.  */
471
static const yytype_uint8 yyprhs[] =
472
{
473
       0,     0,     3,     6,     8,    12,    17,    20,    23,    27,
474
      31,    34,    37,    40,    43,    46,    51,    52,    55,    63,
475
      66,    68,    76,    84,    90,    96,   102,   108,   112,   116,
476
     119,   121,   124,   128,   130,   132,   133,   136,   137,   139,
477
     141,   143,   145,   147,   149,   151,   153,   154,   156,   157,
478
     159,   160,   162,   163,   165,   169,   170,   173,   174,   177,
479
     182,   183,   187,   188,   189,   193,   195,   197,   199
480
};
481
 
482
/* YYRHS -- A `-1'-separated list of the rules' RHS.  */
483
static const yytype_int8 yyrhs[] =
484
{
485
      36,     0,    -1,    36,    37,    -1,    37,    -1,     3,    52,
486
      55,    -1,     4,    52,    55,    56,    -1,    11,    38,    -1,
487
       5,    29,    -1,     6,    30,    46,    -1,     7,    30,    46,
488
      -1,     8,    44,    -1,     9,    44,    -1,    10,    42,    -1,
489
      12,    40,    -1,    13,    30,    -1,    13,    30,    31,    30,
490
      -1,    -1,    38,    39,    -1,    29,    54,    53,    49,    48,
491
      50,    51,    -1,    40,    41,    -1,    41,    -1,    29,    32,
492
      29,    31,    29,    31,    29,    -1,    29,    32,    29,    31,
493
      29,    31,    30,    -1,    29,    32,    29,    31,    29,    -1,
494
      29,    32,    29,    31,    30,    -1,    29,    31,    29,    31,
495
      29,    -1,    29,    31,    29,    31,    30,    -1,    29,    31,
496
      29,    -1,    29,    31,    30,    -1,    42,    43,    -1,    43,
497
      -1,    29,    44,    -1,    44,    45,    47,    -1,    47,    -1,
498
      33,    -1,    -1,    33,    30,    -1,    -1,    16,    -1,    17,
499
      -1,    18,    -1,    19,    -1,    20,    -1,    23,    -1,    24,
500
      -1,    15,    -1,    -1,    21,    -1,    -1,     9,    -1,    -1,
501
      22,    -1,    -1,    29,    -1,    29,    31,    29,    -1,    -1,
502
      34,    30,    -1,    -1,    32,    29,    -1,    32,    29,    31,
503
      29,    -1,    -1,    14,    32,    30,    -1,    -1,    -1,    56,
504
      45,    57,    -1,    25,    -1,    26,    -1,    27,    -1,    28,
505
      -1
506
};
507
 
508
/* YYRLINE[YYN] -- source line where rule number YYN was defined.  */
509
static const yytype_uint8 yyrline[] =
510
{
511
       0,    46,    46,    47,    51,    52,    53,    54,    55,    56,
512
      57,    58,    59,    60,    61,    62,    66,    68,    72,    76,
513
      77,    81,    82,    83,    84,    85,    86,    87,    88,    92,
514
      93,    97,   101,   102,   106,   107,   109,   110,   114,   115,
515
     116,   117,   118,   119,   120,   124,   125,   129,   130,   134,
516
     135,   139,   140,   143,   144,   150,   154,   155,   159,   160,
517
     166,   169,   170,   173,   175,   179,   180,   181,   182
518
};
519
#endif
520
 
521
#if YYDEBUG || YYERROR_VERBOSE || YYTOKEN_TABLE
522
/* YYTNAME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM.
523
   First, the terminals, then, starting at YYNTOKENS, nonterminals.  */
524
static const char *const yytname[] =
525
{
526
  "$end", "error", "$undefined", "NAME", "LIBRARY", "DESCRIPTION",
527
  "STACKSIZE", "HEAPSIZE", "CODE", "DATA", "SECTIONS", "EXPORTS",
528
  "IMPORTS", "VERSIONK", "BASE", "CONSTANT", "READ", "WRITE", "EXECUTE",
529
  "SHARED", "NONSHARED", "NONAME", "PRIVATE", "SINGLE", "MULTIPLE",
530
  "INITINSTANCE", "INITGLOBAL", "TERMINSTANCE", "TERMGLOBAL", "ID",
531
  "NUMBER", "'.'", "'='", "','", "'@'", "$accept", "start", "command",
532
  "explist", "expline", "implist", "impline", "seclist", "secline",
533
  "attr_list", "opt_comma", "opt_number", "attr", "opt_CONSTANT",
534
  "opt_NONAME", "opt_DATA", "opt_PRIVATE", "opt_name", "opt_ordinal",
535
  "opt_equal_name", "opt_base", "option_list", "option", 0
536
};
537
#endif
538
 
539
# ifdef YYPRINT
540
/* YYTOKNUM[YYLEX-NUM] -- Internal token number corresponding to
541
   token YYLEX-NUM.  */
542
static const yytype_uint16 yytoknum[] =
543
{
544
       0,   256,   257,   258,   259,   260,   261,   262,   263,   264,
545
     265,   266,   267,   268,   269,   270,   271,   272,   273,   274,
546
     275,   276,   277,   278,   279,   280,   281,   282,   283,   284,
547
     285,    46,    61,    44,    64
548
};
549
# endif
550
 
551
/* YYR1[YYN] -- Symbol number of symbol that rule YYN derives.  */
552
static const yytype_uint8 yyr1[] =
553
{
554
       0,    35,    36,    36,    37,    37,    37,    37,    37,    37,
555
      37,    37,    37,    37,    37,    37,    38,    38,    39,    40,
556
      40,    41,    41,    41,    41,    41,    41,    41,    41,    42,
557
      42,    43,    44,    44,    45,    45,    46,    46,    47,    47,
558
      47,    47,    47,    47,    47,    48,    48,    49,    49,    50,
559
      50,    51,    51,    52,    52,    52,    53,    53,    54,    54,
560
      54,    55,    55,    56,    56,    57,    57,    57,    57
561
};
562
 
563
/* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN.  */
564
static const yytype_uint8 yyr2[] =
565
{
566
       0,     2,     2,     1,     3,     4,     2,     2,     3,     3,
567
       2,     2,     2,     2,     2,     4,     0,     2,     7,     2,
568
       1,     7,     7,     5,     5,     5,     5,     3,     3,     2,
569
       1,     2,     3,     1,     1,     0,     2,     0,     1,     1,
570
       1,     1,     1,     1,     1,     1,     0,     1,     0,     1,
571
       0,     1,     0,     1,     3,     0,     2,     0,     2,     4,
572
       0,     3,     0,     0,     3,     1,     1,     1,     1
573
};
574
 
575
/* YYDEFACT[STATE-NAME] -- Default rule to reduce with in state
576
   STATE-NUM when YYTABLE doesn't specify something else to do.  Zero
577
   means the default is an error.  */
578
static const yytype_uint8 yydefact[] =
579
{
580
       0,    55,    55,     0,     0,     0,     0,     0,     0,    16,
581
       0,     0,     0,     3,    53,    62,    62,     7,    37,    37,
582
      38,    39,    40,    41,    42,    43,    44,    10,    33,    11,
583
       0,    12,    30,     6,     0,    13,    20,    14,     1,     2,
584
       0,     0,     4,    63,     0,     8,     9,    34,     0,    31,
585
      29,    60,    17,     0,     0,    19,     0,    54,     0,     5,
586
      36,    32,     0,    57,    27,    28,     0,    15,    61,     0,
587
      58,     0,    48,     0,     0,    65,    66,    67,    68,    64,
588
       0,    56,    47,    46,    25,    26,    23,    24,    59,    45,
589
      50,     0,    49,    52,    21,    22,    51,    18
590
};
591
 
592
/* YYDEFGOTO[NTERM-NUM].  */
593
static const yytype_int8 yydefgoto[] =
594
{
595
      -1,    12,    13,    33,    52,    35,    36,    31,    32,    27,
596
      48,    45,    28,    90,    83,    93,    97,    15,    72,    63,
597
      42,    59,    79
598
};
599
 
600
/* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing
601
   STATE-NUM.  */
602
#define YYPACT_NINF -26
603
static const yytype_int8 yypact[] =
604
{
605
      32,   -12,   -12,    17,    -8,    33,    -4,    -4,    35,   -26,
606
      36,    37,    21,   -26,    38,    48,    48,   -26,    39,    39,
607
     -26,   -26,   -26,   -26,   -26,   -26,   -26,   -15,   -26,   -15,
608
      -4,    35,   -26,    41,   -25,    36,   -26,    40,   -26,   -26,
609
      44,    34,   -26,   -26,    45,   -26,   -26,   -26,    -4,   -15,
610
     -26,    42,   -26,   -19,    47,   -26,    49,   -26,    50,    22,
611
     -26,   -26,    52,    43,    51,   -26,    53,   -26,   -26,    26,
612
      54,    56,    57,    27,    29,   -26,   -26,   -26,   -26,   -26,
613
      58,   -26,   -26,    68,   -26,   -26,    59,   -26,   -26,   -26,
614
      79,    31,   -26,    46,   -26,   -26,   -26,   -26
615
};
616
 
617
/* YYPGOTO[NTERM-NUM].  */
618
static const yytype_int8 yypgoto[] =
619
{
620
     -26,   -26,    77,   -26,   -26,   -26,    60,   -26,    61,    -7,
621
      55,    72,    62,   -26,   -26,   -26,   -26,    91,   -26,   -26,
622
      78,   -26,   -26
623
};
624
 
625
/* YYTABLE[YYPACT[STATE-NUM]].  What to do in state STATE-NUM.  If
626
   positive, shift that token.  If negative, reduce the rule which
627
   number is the opposite.  If zero, do what YYDEFACT says.
628
   If YYTABLE_NINF, syntax error.  */
629
#define YYTABLE_NINF -36
630
static const yytype_int8 yytable[] =
631
{
632
      29,   -35,   -35,   -35,   -35,   -35,    53,    54,   -35,   -35,
633
      64,    65,    20,    21,    22,    23,    24,    14,    47,    25,
634
      26,    38,    18,    49,     1,     2,     3,     4,     5,     6,
635
       7,     8,     9,    10,    11,     1,     2,     3,     4,     5,
636
       6,     7,     8,     9,    10,    11,    17,   -35,   -35,   -35,
637
     -35,    75,    76,    77,    78,    47,    84,    85,    86,    87,
638
      94,    95,    41,    19,    30,    34,    58,    37,    96,    40,
639
      51,    56,    44,    57,    62,    60,    66,    71,    82,    67,
640
      68,    70,    73,    89,    74,    80,    81,    88,    92,    39,
641
      91,    46,    50,    16,    43,    55,     0,     0,     0,     0,
642
       0,     0,     0,     0,     0,     0,     0,     0,     0,     0,
643
      61,     0,     0,     0,    69
644
};
645
 
646
static const yytype_int8 yycheck[] =
647
{
648
       7,    16,    17,    18,    19,    20,    31,    32,    23,    24,
649
      29,    30,    16,    17,    18,    19,    20,    29,    33,    23,
650
      24,     0,    30,    30,     3,     4,     5,     6,     7,     8,
651
       9,    10,    11,    12,    13,     3,     4,     5,     6,     7,
652
       8,     9,    10,    11,    12,    13,    29,    25,    26,    27,
653
      28,    25,    26,    27,    28,    33,    29,    30,    29,    30,
654
      29,    30,    14,    30,    29,    29,    32,    30,    22,    31,
655
      29,    31,    33,    29,    32,    30,    29,    34,    21,    30,
656
      30,    29,    31,    15,    31,    31,    30,    29,     9,    12,
657
      31,    19,    31,     2,    16,    35,    -1,    -1,    -1,    -1,
658
      -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
659
      48,    -1,    -1,    -1,    59
660
};
661
 
662
/* YYSTOS[STATE-NUM] -- The (internal number of the) accessing
663
   symbol of state STATE-NUM.  */
664
static const yytype_uint8 yystos[] =
665
{
666
       0,     3,     4,     5,     6,     7,     8,     9,    10,    11,
667
      12,    13,    36,    37,    29,    52,    52,    29,    30,    30,
668
      16,    17,    18,    19,    20,    23,    24,    44,    47,    44,
669
      29,    42,    43,    38,    29,    40,    41,    30,     0,    37,
670
      31,    14,    55,    55,    33,    46,    46,    33,    45,    44,
671
      43,    29,    39,    31,    32,    41,    31,    29,    32,    56,
672
      30,    47,    32,    54,    29,    30,    29,    30,    30,    45,
673
      29,    34,    53,    31,    31,    25,    26,    27,    28,    57,
674
      31,    30,    21,    49,    29,    30,    29,    30,    29,    15,
675
      48,    31,     9,    50,    29,    30,    22,    51
676
};
677
 
678
#define yyerrok         (yyerrstatus = 0)
679
#define yyclearin       (yychar = YYEMPTY)
680
#define YYEMPTY         (-2)
681
#define YYEOF           0
682
 
683
#define YYACCEPT        goto yyacceptlab
684
#define YYABORT         goto yyabortlab
685
#define YYERROR         goto yyerrorlab
686
 
687
 
688
/* Like YYERROR except do call yyerror.  This remains here temporarily
689
   to ease the transition to the new meaning of YYERROR, for GCC.
690
   Once GCC version 2 has supplanted version 1, this can go.  */
691
 
692
#define YYFAIL          goto yyerrlab
693
 
694
#define YYRECOVERING()  (!!yyerrstatus)
695
 
696
#define YYBACKUP(Token, Value)                                  \
697
do                                                              \
698
  if (yychar == YYEMPTY && yylen == 1)                          \
699
    {                                                           \
700
      yychar = (Token);                                         \
701
      yylval = (Value);                                         \
702
      yytoken = YYTRANSLATE (yychar);                           \
703
      YYPOPSTACK (1);                                           \
704
      goto yybackup;                                            \
705
    }                                                           \
706
  else                                                          \
707
    {                                                           \
708
      yyerror (YY_("syntax error: cannot back up")); \
709
      YYERROR;                                                  \
710
    }                                                           \
711
while (YYID (0))
712
 
713
 
714
#define YYTERROR        1
715
#define YYERRCODE       256
716
 
717
 
718
/* YYLLOC_DEFAULT -- Set CURRENT to span from RHS[1] to RHS[N].
719
   If N is 0, then set CURRENT to the empty location which ends
720
   the previous symbol: RHS[0] (always defined).  */
721
 
722
#define YYRHSLOC(Rhs, K) ((Rhs)[K])
723
#ifndef YYLLOC_DEFAULT
724
# define YYLLOC_DEFAULT(Current, Rhs, N)                                \
725
    do                                                                  \
726
      if (YYID (N))                                                    \
727
        {                                                               \
728
          (Current).first_line   = YYRHSLOC (Rhs, 1).first_line;        \
729
          (Current).first_column = YYRHSLOC (Rhs, 1).first_column;      \
730
          (Current).last_line    = YYRHSLOC (Rhs, N).last_line;         \
731
          (Current).last_column  = YYRHSLOC (Rhs, N).last_column;       \
732
        }                                                               \
733
      else                                                              \
734
        {                                                               \
735
          (Current).first_line   = (Current).last_line   =              \
736
            YYRHSLOC (Rhs, 0).last_line;                         \
737
          (Current).first_column = (Current).last_column =              \
738
            YYRHSLOC (Rhs, 0).last_column;                               \
739
        }                                                               \
740
    while (YYID (0))
741
#endif
742
 
743
 
744
/* YY_LOCATION_PRINT -- Print the location on the stream.
745
   This macro was not mandated originally: define only if we know
746
   we won't break user code: when these are the locations we know.  */
747
 
748
#ifndef YY_LOCATION_PRINT
749
# if defined YYLTYPE_IS_TRIVIAL && YYLTYPE_IS_TRIVIAL
750
#  define YY_LOCATION_PRINT(File, Loc)                  \
751
     fprintf (File, "%d.%d-%d.%d",                      \
752
              (Loc).first_line, (Loc).first_column,     \
753
              (Loc).last_line,  (Loc).last_column)
754
# else
755
#  define YY_LOCATION_PRINT(File, Loc) ((void) 0)
756
# endif
757
#endif
758
 
759
 
760
/* YYLEX -- calling `yylex' with the right arguments.  */
761
 
762
#ifdef YYLEX_PARAM
763
# define YYLEX yylex (YYLEX_PARAM)
764
#else
765
# define YYLEX yylex ()
766
#endif
767
 
768
/* Enable debugging if requested.  */
769
#if YYDEBUG
770
 
771
# ifndef YYFPRINTF
772
#  include <stdio.h> /* INFRINGES ON USER NAME SPACE */
773
#  define YYFPRINTF fprintf
774
# endif
775
 
776
# define YYDPRINTF(Args)                        \
777
do {                                            \
778
  if (yydebug)                                  \
779
    YYFPRINTF Args;                             \
780
} while (YYID (0))
781
 
782
# define YY_SYMBOL_PRINT(Title, Type, Value, Location)                    \
783
do {                                                                      \
784
  if (yydebug)                                                            \
785
    {                                                                     \
786
      YYFPRINTF (stderr, "%s ", Title);                                   \
787
      yy_symbol_print (stderr,                                            \
788
                  Type, Value); \
789
      YYFPRINTF (stderr, "\n");                                           \
790
    }                                                                     \
791
} while (YYID (0))
792
 
793
 
794
/*--------------------------------.
795
| Print this symbol on YYOUTPUT.  |
796
`--------------------------------*/
797
 
798
/*ARGSUSED*/
799
#if (defined __STDC__ || defined __C99__FUNC__ \
800
     || defined __cplusplus || defined _MSC_VER)
801
static void
802
yy_symbol_value_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep)
803
#else
804
static void
805
yy_symbol_value_print (yyoutput, yytype, yyvaluep)
806
    FILE *yyoutput;
807
    int yytype;
808
    YYSTYPE const * const yyvaluep;
809
#endif
810
{
811
  if (!yyvaluep)
812
    return;
813
# ifdef YYPRINT
814
  if (yytype < YYNTOKENS)
815
    YYPRINT (yyoutput, yytoknum[yytype], *yyvaluep);
816
# else
817
  YYUSE (yyoutput);
818
# endif
819
  switch (yytype)
820
    {
821
      default:
822
        break;
823
    }
824
}
825
 
826
 
827
/*--------------------------------.
828
| Print this symbol on YYOUTPUT.  |
829
`--------------------------------*/
830
 
831
#if (defined __STDC__ || defined __C99__FUNC__ \
832
     || defined __cplusplus || defined _MSC_VER)
833
static void
834
yy_symbol_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep)
835
#else
836
static void
837
yy_symbol_print (yyoutput, yytype, yyvaluep)
838
    FILE *yyoutput;
839
    int yytype;
840
    YYSTYPE const * const yyvaluep;
841
#endif
842
{
843
  if (yytype < YYNTOKENS)
844
    YYFPRINTF (yyoutput, "token %s (", yytname[yytype]);
845
  else
846
    YYFPRINTF (yyoutput, "nterm %s (", yytname[yytype]);
847
 
848
  yy_symbol_value_print (yyoutput, yytype, yyvaluep);
849
  YYFPRINTF (yyoutput, ")");
850
}
851
 
852
/*------------------------------------------------------------------.
853
| yy_stack_print -- Print the state stack from its BOTTOM up to its |
854
| TOP (included).                                                   |
855
`------------------------------------------------------------------*/
856
 
857
#if (defined __STDC__ || defined __C99__FUNC__ \
858
     || defined __cplusplus || defined _MSC_VER)
859
static void
860
yy_stack_print (yytype_int16 *bottom, yytype_int16 *top)
861
#else
862
static void
863
yy_stack_print (bottom, top)
864
    yytype_int16 *bottom;
865
    yytype_int16 *top;
866
#endif
867
{
868
  YYFPRINTF (stderr, "Stack now");
869
  for (; bottom <= top; ++bottom)
870
    YYFPRINTF (stderr, " %d", *bottom);
871
  YYFPRINTF (stderr, "\n");
872
}
873
 
874
# define YY_STACK_PRINT(Bottom, Top)                            \
875
do {                                                            \
876
  if (yydebug)                                                  \
877
    yy_stack_print ((Bottom), (Top));                           \
878
} while (YYID (0))
879
 
880
 
881
/*------------------------------------------------.
882
| Report that the YYRULE is going to be reduced.  |
883
`------------------------------------------------*/
884
 
885
#if (defined __STDC__ || defined __C99__FUNC__ \
886
     || defined __cplusplus || defined _MSC_VER)
887
static void
888
yy_reduce_print (YYSTYPE *yyvsp, int yyrule)
889
#else
890
static void
891
yy_reduce_print (yyvsp, yyrule)
892
    YYSTYPE *yyvsp;
893
    int yyrule;
894
#endif
895
{
896
  int yynrhs = yyr2[yyrule];
897
  int yyi;
898
  unsigned long int yylno = yyrline[yyrule];
899
  YYFPRINTF (stderr, "Reducing stack by rule %d (line %lu):\n",
900
             yyrule - 1, yylno);
901
  /* The symbols being reduced.  */
902
  for (yyi = 0; yyi < yynrhs; yyi++)
903
    {
904
      fprintf (stderr, "   $%d = ", yyi + 1);
905
      yy_symbol_print (stderr, yyrhs[yyprhs[yyrule] + yyi],
906
                       &(yyvsp[(yyi + 1) - (yynrhs)])
907
                                       );
908
      fprintf (stderr, "\n");
909
    }
910
}
911
 
912
# define YY_REDUCE_PRINT(Rule)          \
913
do {                                    \
914
  if (yydebug)                          \
915
    yy_reduce_print (yyvsp, Rule); \
916
} while (YYID (0))
917
 
918
/* Nonzero means print parse trace.  It is left uninitialized so that
919
   multiple parsers can coexist.  */
920
int yydebug;
921
#else /* !YYDEBUG */
922
# define YYDPRINTF(Args)
923
# define YY_SYMBOL_PRINT(Title, Type, Value, Location)
924
# define YY_STACK_PRINT(Bottom, Top)
925
# define YY_REDUCE_PRINT(Rule)
926
#endif /* !YYDEBUG */
927
 
928
 
929
/* YYINITDEPTH -- initial size of the parser's stacks.  */
930
#ifndef YYINITDEPTH
931
# define YYINITDEPTH 200
932
#endif
933
 
934
/* YYMAXDEPTH -- maximum size the stacks can grow to (effective only
935
   if the built-in stack extension method is used).
936
 
937
   Do not make this value too large; the results are undefined if
938
   YYSTACK_ALLOC_MAXIMUM < YYSTACK_BYTES (YYMAXDEPTH)
939
   evaluated with infinite-precision integer arithmetic.  */
940
 
941
#ifndef YYMAXDEPTH
942
# define YYMAXDEPTH 10000
943
#endif
944
 
945
 
946
 
947
#if YYERROR_VERBOSE
948
 
949
# ifndef yystrlen
950
#  if defined __GLIBC__ && defined _STRING_H
951
#   define yystrlen strlen
952
#  else
953
/* Return the length of YYSTR.  */
954
#if (defined __STDC__ || defined __C99__FUNC__ \
955
     || defined __cplusplus || defined _MSC_VER)
956
static YYSIZE_T
957
yystrlen (const char *yystr)
958
#else
959
static YYSIZE_T
960
yystrlen (yystr)
961
    const char *yystr;
962
#endif
963
{
964
  YYSIZE_T yylen;
965
  for (yylen = 0; yystr[yylen]; yylen++)
966
    continue;
967
  return yylen;
968
}
969
#  endif
970
# endif
971
 
972
# ifndef yystpcpy
973
#  if defined __GLIBC__ && defined _STRING_H && defined _GNU_SOURCE
974
#   define yystpcpy stpcpy
975
#  else
976
/* Copy YYSRC to YYDEST, returning the address of the terminating '\0' in
977
   YYDEST.  */
978
#if (defined __STDC__ || defined __C99__FUNC__ \
979
     || defined __cplusplus || defined _MSC_VER)
980
static char *
981
yystpcpy (char *yydest, const char *yysrc)
982
#else
983
static char *
984
yystpcpy (yydest, yysrc)
985
    char *yydest;
986
    const char *yysrc;
987
#endif
988
{
989
  char *yyd = yydest;
990
  const char *yys = yysrc;
991
 
992
  while ((*yyd++ = *yys++) != '\0')
993
    continue;
994
 
995
  return yyd - 1;
996
}
997
#  endif
998
# endif
999
 
1000
# ifndef yytnamerr
1001
/* Copy to YYRES the contents of YYSTR after stripping away unnecessary
1002
   quotes and backslashes, so that it's suitable for yyerror.  The
1003
   heuristic is that double-quoting is unnecessary unless the string
1004
   contains an apostrophe, a comma, or backslash (other than
1005
   backslash-backslash).  YYSTR is taken from yytname.  If YYRES is
1006
   null, do not copy; instead, return the length of what the result
1007
   would have been.  */
1008
static YYSIZE_T
1009
yytnamerr (char *yyres, const char *yystr)
1010
{
1011
  if (*yystr == '"')
1012
    {
1013
      YYSIZE_T yyn = 0;
1014
      char const *yyp = yystr;
1015
 
1016
      for (;;)
1017
        switch (*++yyp)
1018
          {
1019
          case '\'':
1020
          case ',':
1021
            goto do_not_strip_quotes;
1022
 
1023
          case '\\':
1024
            if (*++yyp != '\\')
1025
              goto do_not_strip_quotes;
1026
            /* Fall through.  */
1027
          default:
1028
            if (yyres)
1029
              yyres[yyn] = *yyp;
1030
            yyn++;
1031
            break;
1032
 
1033
          case '"':
1034
            if (yyres)
1035
              yyres[yyn] = '\0';
1036
            return yyn;
1037
          }
1038
    do_not_strip_quotes: ;
1039
    }
1040
 
1041
  if (! yyres)
1042
    return yystrlen (yystr);
1043
 
1044
  return yystpcpy (yyres, yystr) - yyres;
1045
}
1046
# endif
1047
 
1048
/* Copy into YYRESULT an error message about the unexpected token
1049
   YYCHAR while in state YYSTATE.  Return the number of bytes copied,
1050
   including the terminating null byte.  If YYRESULT is null, do not
1051
   copy anything; just return the number of bytes that would be
1052
   copied.  As a special case, return 0 if an ordinary "syntax error"
1053
   message will do.  Return YYSIZE_MAXIMUM if overflow occurs during
1054
   size calculation.  */
1055
static YYSIZE_T
1056
yysyntax_error (char *yyresult, int yystate, int yychar)
1057
{
1058
  int yyn = yypact[yystate];
1059
 
1060
  if (! (YYPACT_NINF < yyn && yyn <= YYLAST))
1061
    return 0;
1062
  else
1063
    {
1064
      int yytype = YYTRANSLATE (yychar);
1065
      YYSIZE_T yysize0 = yytnamerr (0, yytname[yytype]);
1066
      YYSIZE_T yysize = yysize0;
1067
      YYSIZE_T yysize1;
1068
      int yysize_overflow = 0;
1069
      enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 };
1070
      char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM];
1071
      int yyx;
1072
 
1073
# if 0
1074
      /* This is so xgettext sees the translatable formats that are
1075
         constructed on the fly.  */
1076
      YY_("syntax error, unexpected %s");
1077
      YY_("syntax error, unexpected %s, expecting %s");
1078
      YY_("syntax error, unexpected %s, expecting %s or %s");
1079
      YY_("syntax error, unexpected %s, expecting %s or %s or %s");
1080
      YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s");
1081
# endif
1082
      char *yyfmt;
1083
      char const *yyf;
1084
      static char const yyunexpected[] = "syntax error, unexpected %s";
1085
      static char const yyexpecting[] = ", expecting %s";
1086
      static char const yyor[] = " or %s";
1087
      char yyformat[sizeof yyunexpected
1088
                    + sizeof yyexpecting - 1
1089
                    + ((YYERROR_VERBOSE_ARGS_MAXIMUM - 2)
1090
                       * (sizeof yyor - 1))];
1091
      char const *yyprefix = yyexpecting;
1092
 
1093
      /* Start YYX at -YYN if negative to avoid negative indexes in
1094
         YYCHECK.  */
1095
      int yyxbegin = yyn < 0 ? -yyn : 0;
1096
 
1097
      /* Stay within bounds of both yycheck and yytname.  */
1098
      int yychecklim = YYLAST - yyn + 1;
1099
      int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS;
1100
      int yycount = 1;
1101
 
1102
      yyarg[0] = yytname[yytype];
1103
      yyfmt = yystpcpy (yyformat, yyunexpected);
1104
 
1105
      for (yyx = yyxbegin; yyx < yyxend; ++yyx)
1106
        if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR)
1107
          {
1108
            if (yycount == YYERROR_VERBOSE_ARGS_MAXIMUM)
1109
              {
1110
                yycount = 1;
1111
                yysize = yysize0;
1112
                yyformat[sizeof yyunexpected - 1] = '\0';
1113
                break;
1114
              }
1115
            yyarg[yycount++] = yytname[yyx];
1116
            yysize1 = yysize + yytnamerr (0, yytname[yyx]);
1117
            yysize_overflow |= (yysize1 < yysize);
1118
            yysize = yysize1;
1119
            yyfmt = yystpcpy (yyfmt, yyprefix);
1120
            yyprefix = yyor;
1121
          }
1122
 
1123
      yyf = YY_(yyformat);
1124
      yysize1 = yysize + yystrlen (yyf);
1125
      yysize_overflow |= (yysize1 < yysize);
1126
      yysize = yysize1;
1127
 
1128
      if (yysize_overflow)
1129
        return YYSIZE_MAXIMUM;
1130
 
1131
      if (yyresult)
1132
        {
1133
          /* Avoid sprintf, as that infringes on the user's name space.
1134
             Don't have undefined behavior even if the translation
1135
             produced a string with the wrong number of "%s"s.  */
1136
          char *yyp = yyresult;
1137
          int yyi = 0;
1138
          while ((*yyp = *yyf) != '\0')
1139
            {
1140
              if (*yyp == '%' && yyf[1] == 's' && yyi < yycount)
1141
                {
1142
                  yyp += yytnamerr (yyp, yyarg[yyi++]);
1143
                  yyf += 2;
1144
                }
1145
              else
1146
                {
1147
                  yyp++;
1148
                  yyf++;
1149
                }
1150
            }
1151
        }
1152
      return yysize;
1153
    }
1154
}
1155
#endif /* YYERROR_VERBOSE */
1156
 
1157
 
1158
/*-----------------------------------------------.
1159
| Release the memory associated to this symbol.  |
1160
`-----------------------------------------------*/
1161
 
1162
/*ARGSUSED*/
1163
#if (defined __STDC__ || defined __C99__FUNC__ \
1164
     || defined __cplusplus || defined _MSC_VER)
1165
static void
1166
yydestruct (const char *yymsg, int yytype, YYSTYPE *yyvaluep)
1167
#else
1168
static void
1169
yydestruct (yymsg, yytype, yyvaluep)
1170
    const char *yymsg;
1171
    int yytype;
1172
    YYSTYPE *yyvaluep;
1173
#endif
1174
{
1175
  YYUSE (yyvaluep);
1176
 
1177
  if (!yymsg)
1178
    yymsg = "Deleting";
1179
  YY_SYMBOL_PRINT (yymsg, yytype, yyvaluep, yylocationp);
1180
 
1181
  switch (yytype)
1182
    {
1183
 
1184
      default:
1185
        break;
1186
    }
1187
}
1188
 
1189
 
1190
/* Prevent warnings from -Wmissing-prototypes.  */
1191
 
1192
#ifdef YYPARSE_PARAM
1193
#if defined __STDC__ || defined __cplusplus
1194
int yyparse (void *YYPARSE_PARAM);
1195
#else
1196
int yyparse ();
1197
#endif
1198
#else /* ! YYPARSE_PARAM */
1199
#if defined __STDC__ || defined __cplusplus
1200
int yyparse (void);
1201
#else
1202
int yyparse ();
1203
#endif
1204
#endif /* ! YYPARSE_PARAM */
1205
 
1206
 
1207
 
1208
/* The look-ahead symbol.  */
1209
int yychar;
1210
 
1211
/* The semantic value of the look-ahead symbol.  */
1212
YYSTYPE yylval;
1213
 
1214
/* Number of syntax errors so far.  */
1215
int yynerrs;
1216
 
1217
 
1218
 
1219
/*----------.
1220
| yyparse.  |
1221
`----------*/
1222
 
1223
#ifdef YYPARSE_PARAM
1224
#if (defined __STDC__ || defined __C99__FUNC__ \
1225
     || defined __cplusplus || defined _MSC_VER)
1226
int
1227
yyparse (void *YYPARSE_PARAM)
1228
#else
1229
int
1230
yyparse (YYPARSE_PARAM)
1231
    void *YYPARSE_PARAM;
1232
#endif
1233
#else /* ! YYPARSE_PARAM */
1234
#if (defined __STDC__ || defined __C99__FUNC__ \
1235
     || defined __cplusplus || defined _MSC_VER)
1236
int
1237
yyparse (void)
1238
#else
1239
int
1240
yyparse ()
1241
 
1242
#endif
1243
#endif
1244
{
1245
 
1246
  int yystate;
1247
  int yyn;
1248
  int yyresult;
1249
  /* Number of tokens to shift before error messages enabled.  */
1250
  int yyerrstatus;
1251
  /* Look-ahead token as an internal (translated) token number.  */
1252
  int yytoken = 0;
1253
#if YYERROR_VERBOSE
1254
  /* Buffer for error messages, and its allocated size.  */
1255
  char yymsgbuf[128];
1256
  char *yymsg = yymsgbuf;
1257
  YYSIZE_T yymsg_alloc = sizeof yymsgbuf;
1258
#endif
1259
 
1260
  /* Three stacks and their tools:
1261
     `yyss': related to states,
1262
     `yyvs': related to semantic values,
1263
     `yyls': related to locations.
1264
 
1265
     Refer to the stacks thru separate pointers, to allow yyoverflow
1266
     to reallocate them elsewhere.  */
1267
 
1268
  /* The state stack.  */
1269
  yytype_int16 yyssa[YYINITDEPTH];
1270
  yytype_int16 *yyss = yyssa;
1271
  yytype_int16 *yyssp;
1272
 
1273
  /* The semantic value stack.  */
1274
  YYSTYPE yyvsa[YYINITDEPTH];
1275
  YYSTYPE *yyvs = yyvsa;
1276
  YYSTYPE *yyvsp;
1277
 
1278
 
1279
 
1280
#define YYPOPSTACK(N)   (yyvsp -= (N), yyssp -= (N))
1281
 
1282
  YYSIZE_T yystacksize = YYINITDEPTH;
1283
 
1284
  /* The variables used to return semantic value and location from the
1285
     action routines.  */
1286
  YYSTYPE yyval;
1287
 
1288
 
1289
  /* The number of symbols on the RHS of the reduced rule.
1290
     Keep to zero when no symbol should be popped.  */
1291
  int yylen = 0;
1292
 
1293
  YYDPRINTF ((stderr, "Starting parse\n"));
1294
 
1295
  yystate = 0;
1296
  yyerrstatus = 0;
1297
  yynerrs = 0;
1298
  yychar = YYEMPTY;             /* Cause a token to be read.  */
1299
 
1300
  /* Initialize stack pointers.
1301
     Waste one element of value and location stack
1302
     so that they stay on the same level as the state stack.
1303
     The wasted elements are never initialized.  */
1304
 
1305
  yyssp = yyss;
1306
  yyvsp = yyvs;
1307
 
1308
  goto yysetstate;
1309
 
1310
/*------------------------------------------------------------.
1311
| yynewstate -- Push a new state, which is found in yystate.  |
1312
`------------------------------------------------------------*/
1313
 yynewstate:
1314
  /* In all cases, when you get here, the value and location stacks
1315
     have just been pushed.  So pushing a state here evens the stacks.  */
1316
  yyssp++;
1317
 
1318
 yysetstate:
1319
  *yyssp = yystate;
1320
 
1321
  if (yyss + yystacksize - 1 <= yyssp)
1322
    {
1323
      /* Get the current used size of the three stacks, in elements.  */
1324
      YYSIZE_T yysize = yyssp - yyss + 1;
1325
 
1326
#ifdef yyoverflow
1327
      {
1328
        /* Give user a chance to reallocate the stack.  Use copies of
1329
           these so that the &'s don't force the real ones into
1330
           memory.  */
1331
        YYSTYPE *yyvs1 = yyvs;
1332
        yytype_int16 *yyss1 = yyss;
1333
 
1334
 
1335
        /* Each stack pointer address is followed by the size of the
1336
           data in use in that stack, in bytes.  This used to be a
1337
           conditional around just the two extra args, but that might
1338
           be undefined if yyoverflow is a macro.  */
1339
        yyoverflow (YY_("memory exhausted"),
1340
                    &yyss1, yysize * sizeof (*yyssp),
1341
                    &yyvs1, yysize * sizeof (*yyvsp),
1342
 
1343
                    &yystacksize);
1344
 
1345
        yyss = yyss1;
1346
        yyvs = yyvs1;
1347
      }
1348
#else /* no yyoverflow */
1349
# ifndef YYSTACK_RELOCATE
1350
      goto yyexhaustedlab;
1351
# else
1352
      /* Extend the stack our own way.  */
1353
      if (YYMAXDEPTH <= yystacksize)
1354
        goto yyexhaustedlab;
1355
      yystacksize *= 2;
1356
      if (YYMAXDEPTH < yystacksize)
1357
        yystacksize = YYMAXDEPTH;
1358
 
1359
      {
1360
        yytype_int16 *yyss1 = yyss;
1361
        union yyalloc *yyptr =
1362
          (union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize));
1363
        if (! yyptr)
1364
          goto yyexhaustedlab;
1365
        YYSTACK_RELOCATE (yyss);
1366
        YYSTACK_RELOCATE (yyvs);
1367
 
1368
#  undef YYSTACK_RELOCATE
1369
        if (yyss1 != yyssa)
1370
          YYSTACK_FREE (yyss1);
1371
      }
1372
# endif
1373
#endif /* no yyoverflow */
1374
 
1375
      yyssp = yyss + yysize - 1;
1376
      yyvsp = yyvs + yysize - 1;
1377
 
1378
 
1379
      YYDPRINTF ((stderr, "Stack size increased to %lu\n",
1380
                  (unsigned long int) yystacksize));
1381
 
1382
      if (yyss + yystacksize - 1 <= yyssp)
1383
        YYABORT;
1384
    }
1385
 
1386
  YYDPRINTF ((stderr, "Entering state %d\n", yystate));
1387
 
1388
  goto yybackup;
1389
 
1390
/*-----------.
1391
| yybackup.  |
1392
`-----------*/
1393
yybackup:
1394
 
1395
  /* Do appropriate processing given the current state.  Read a
1396
     look-ahead token if we need one and don't already have one.  */
1397
 
1398
  /* First try to decide what to do without reference to look-ahead token.  */
1399
  yyn = yypact[yystate];
1400
  if (yyn == YYPACT_NINF)
1401
    goto yydefault;
1402
 
1403
  /* Not known => get a look-ahead token if don't already have one.  */
1404
 
1405
  /* YYCHAR is either YYEMPTY or YYEOF or a valid look-ahead symbol.  */
1406
  if (yychar == YYEMPTY)
1407
    {
1408
      YYDPRINTF ((stderr, "Reading a token: "));
1409
      yychar = YYLEX;
1410
    }
1411
 
1412
  if (yychar <= YYEOF)
1413
    {
1414
      yychar = yytoken = YYEOF;
1415
      YYDPRINTF ((stderr, "Now at end of input.\n"));
1416
    }
1417
  else
1418
    {
1419
      yytoken = YYTRANSLATE (yychar);
1420
      YY_SYMBOL_PRINT ("Next token is", yytoken, &yylval, &yylloc);
1421
    }
1422
 
1423
  /* If the proper action on seeing token YYTOKEN is to reduce or to
1424
     detect an error, take that action.  */
1425
  yyn += yytoken;
1426
  if (yyn < 0 || YYLAST < yyn || yycheck[yyn] != yytoken)
1427
    goto yydefault;
1428
  yyn = yytable[yyn];
1429
  if (yyn <= 0)
1430
    {
1431
      if (yyn == 0 || yyn == YYTABLE_NINF)
1432
        goto yyerrlab;
1433
      yyn = -yyn;
1434
      goto yyreduce;
1435
    }
1436
 
1437
  if (yyn == YYFINAL)
1438
    YYACCEPT;
1439
 
1440
  /* Count tokens shifted since error; after three, turn off error
1441
     status.  */
1442
  if (yyerrstatus)
1443
    yyerrstatus--;
1444
 
1445
  /* Shift the look-ahead token.  */
1446
  YY_SYMBOL_PRINT ("Shifting", yytoken, &yylval, &yylloc);
1447
 
1448
  /* Discard the shifted token unless it is eof.  */
1449
  if (yychar != YYEOF)
1450
    yychar = YYEMPTY;
1451
 
1452
  yystate = yyn;
1453
  *++yyvsp = yylval;
1454
 
1455
  goto yynewstate;
1456
 
1457
 
1458
/*-----------------------------------------------------------.
1459
| yydefault -- do the default action for the current state.  |
1460
`-----------------------------------------------------------*/
1461
yydefault:
1462
  yyn = yydefact[yystate];
1463
  if (yyn == 0)
1464
    goto yyerrlab;
1465
  goto yyreduce;
1466
 
1467
 
1468
/*-----------------------------.
1469
| yyreduce -- Do a reduction.  |
1470
`-----------------------------*/
1471
yyreduce:
1472
  /* yyn is the number of a rule to reduce with.  */
1473
  yylen = yyr2[yyn];
1474
 
1475
  /* If YYLEN is nonzero, implement the default value of the action:
1476
     `$$ = $1'.
1477
 
1478
     Otherwise, the following line sets YYVAL to garbage.
1479
     This behavior is undocumented and Bison
1480
     users should not rely upon it.  Assigning to YYVAL
1481
     unconditionally makes the parser a bit smaller, and it avoids a
1482
     GCC warning that YYVAL may be used uninitialized.  */
1483
  yyval = yyvsp[1-yylen];
1484
 
1485
 
1486
  YY_REDUCE_PRINT (yyn);
1487
  switch (yyn)
1488
    {
1489
        case 4:
1490
#line 51 "defparse.y"
1491
    { def_name ((yyvsp[(2) - (3)].id), (yyvsp[(3) - (3)].number)); }
1492
    break;
1493
 
1494
  case 5:
1495
#line 52 "defparse.y"
1496
    { def_library ((yyvsp[(2) - (4)].id), (yyvsp[(3) - (4)].number)); }
1497
    break;
1498
 
1499
  case 7:
1500
#line 54 "defparse.y"
1501
    { def_description ((yyvsp[(2) - (2)].id));}
1502
    break;
1503
 
1504
  case 8:
1505
#line 55 "defparse.y"
1506
    { def_stacksize ((yyvsp[(2) - (3)].number), (yyvsp[(3) - (3)].number));}
1507
    break;
1508
 
1509
  case 9:
1510
#line 56 "defparse.y"
1511
    { def_heapsize ((yyvsp[(2) - (3)].number), (yyvsp[(3) - (3)].number));}
1512
    break;
1513
 
1514
  case 10:
1515
#line 57 "defparse.y"
1516
    { def_code ((yyvsp[(2) - (2)].number));}
1517
    break;
1518
 
1519
  case 11:
1520
#line 58 "defparse.y"
1521
    { def_data ((yyvsp[(2) - (2)].number));}
1522
    break;
1523
 
1524
  case 14:
1525
#line 61 "defparse.y"
1526
    { def_version ((yyvsp[(2) - (2)].number),0);}
1527
    break;
1528
 
1529
  case 15:
1530
#line 62 "defparse.y"
1531
    { def_version ((yyvsp[(2) - (4)].number),(yyvsp[(4) - (4)].number));}
1532
    break;
1533
 
1534
  case 18:
1535
#line 73 "defparse.y"
1536
    { def_exports ((yyvsp[(1) - (7)].id), (yyvsp[(2) - (7)].id), (yyvsp[(3) - (7)].number), (yyvsp[(4) - (7)].number), (yyvsp[(5) - (7)].number), (yyvsp[(6) - (7)].number), (yyvsp[(7) - (7)].number));}
1537
    break;
1538
 
1539
  case 21:
1540
#line 81 "defparse.y"
1541
    { def_import ((yyvsp[(1) - (7)].id),(yyvsp[(3) - (7)].id),(yyvsp[(5) - (7)].id),(yyvsp[(7) - (7)].id), 0); }
1542
    break;
1543
 
1544
  case 22:
1545
#line 82 "defparse.y"
1546
    { def_import ((yyvsp[(1) - (7)].id),(yyvsp[(3) - (7)].id),(yyvsp[(5) - (7)].id), 0,(yyvsp[(7) - (7)].number)); }
1547
    break;
1548
 
1549
  case 23:
1550
#line 83 "defparse.y"
1551
    { def_import ((yyvsp[(1) - (5)].id),(yyvsp[(3) - (5)].id), 0,(yyvsp[(5) - (5)].id), 0); }
1552
    break;
1553
 
1554
  case 24:
1555
#line 84 "defparse.y"
1556
    { def_import ((yyvsp[(1) - (5)].id),(yyvsp[(3) - (5)].id), 0, 0,(yyvsp[(5) - (5)].number)); }
1557
    break;
1558
 
1559
  case 25:
1560
#line 85 "defparse.y"
1561
    { def_import ( 0,(yyvsp[(1) - (5)].id),(yyvsp[(3) - (5)].id),(yyvsp[(5) - (5)].id), 0); }
1562
    break;
1563
 
1564
  case 26:
1565
#line 86 "defparse.y"
1566
    { def_import ( 0,(yyvsp[(1) - (5)].id),(yyvsp[(3) - (5)].id), 0,(yyvsp[(5) - (5)].number)); }
1567
    break;
1568
 
1569
  case 27:
1570
#line 87 "defparse.y"
1571
    { def_import ( 0,(yyvsp[(1) - (3)].id), 0,(yyvsp[(3) - (3)].id), 0); }
1572
    break;
1573
 
1574
  case 28:
1575
#line 88 "defparse.y"
1576
    { def_import ( 0,(yyvsp[(1) - (3)].id), 0, 0,(yyvsp[(3) - (3)].number)); }
1577
    break;
1578
 
1579
  case 31:
1580
#line 97 "defparse.y"
1581
    { def_section ((yyvsp[(1) - (2)].id),(yyvsp[(2) - (2)].number));}
1582
    break;
1583
 
1584
  case 36:
1585
#line 109 "defparse.y"
1586
    { (yyval.number)=(yyvsp[(2) - (2)].number);}
1587
    break;
1588
 
1589
  case 37:
1590
#line 110 "defparse.y"
1591
    { (yyval.number)=-1;}
1592
    break;
1593
 
1594
  case 38:
1595
#line 114 "defparse.y"
1596
    { (yyval.number) = 1; }
1597
    break;
1598
 
1599
  case 39:
1600
#line 115 "defparse.y"
1601
    { (yyval.number) = 2; }
1602
    break;
1603
 
1604
  case 40:
1605
#line 116 "defparse.y"
1606
    { (yyval.number) = 4; }
1607
    break;
1608
 
1609
  case 41:
1610
#line 117 "defparse.y"
1611
    { (yyval.number) = 8; }
1612
    break;
1613
 
1614
  case 42:
1615
#line 118 "defparse.y"
1616
    { (yyval.number) = 0; }
1617
    break;
1618
 
1619
  case 43:
1620
#line 119 "defparse.y"
1621
    { (yyval.number) = 0; }
1622
    break;
1623
 
1624
  case 44:
1625
#line 120 "defparse.y"
1626
    { (yyval.number) = 0; }
1627
    break;
1628
 
1629
  case 45:
1630
#line 124 "defparse.y"
1631
    {(yyval.number)=1;}
1632
    break;
1633
 
1634
  case 46:
1635
#line 125 "defparse.y"
1636
    {(yyval.number)=0;}
1637
    break;
1638
 
1639
  case 47:
1640
#line 129 "defparse.y"
1641
    {(yyval.number)=1;}
1642
    break;
1643
 
1644
  case 48:
1645
#line 130 "defparse.y"
1646
    {(yyval.number)=0;}
1647
    break;
1648
 
1649
  case 49:
1650
#line 134 "defparse.y"
1651
    { (yyval.number) = 1; }
1652
    break;
1653
 
1654
  case 50:
1655
#line 135 "defparse.y"
1656
    { (yyval.number) = 0; }
1657
    break;
1658
 
1659
  case 51:
1660
#line 139 "defparse.y"
1661
    { (yyval.number) = 1; }
1662
    break;
1663
 
1664
  case 52:
1665
#line 140 "defparse.y"
1666
    { (yyval.number) = 0; }
1667
    break;
1668
 
1669
  case 53:
1670
#line 143 "defparse.y"
1671
    { (yyval.id) =(yyvsp[(1) - (1)].id); }
1672
    break;
1673
 
1674
  case 54:
1675
#line 145 "defparse.y"
1676
    {
1677
            char *name = xmalloc (strlen ((yyvsp[(1) - (3)].id)) + 1 + strlen ((yyvsp[(3) - (3)].id)) + 1);
1678
            sprintf (name, "%s.%s", (yyvsp[(1) - (3)].id), (yyvsp[(3) - (3)].id));
1679
            (yyval.id) = name;
1680
          }
1681
    break;
1682
 
1683
  case 55:
1684
#line 150 "defparse.y"
1685
    { (yyval.id)=""; }
1686
    break;
1687
 
1688
  case 56:
1689
#line 154 "defparse.y"
1690
    { (yyval.number)=(yyvsp[(2) - (2)].number);}
1691
    break;
1692
 
1693
  case 57:
1694
#line 155 "defparse.y"
1695
    { (yyval.number)=-1;}
1696
    break;
1697
 
1698
  case 58:
1699
#line 159 "defparse.y"
1700
    { (yyval.id) = (yyvsp[(2) - (2)].id); }
1701
    break;
1702
 
1703
  case 59:
1704
#line 161 "defparse.y"
1705
    {
1706
            char *name = xmalloc (strlen ((yyvsp[(2) - (4)].id)) + 1 + strlen ((yyvsp[(4) - (4)].id)) + 1);
1707
            sprintf (name, "%s.%s", (yyvsp[(2) - (4)].id), (yyvsp[(4) - (4)].id));
1708
            (yyval.id) = name;
1709
          }
1710
    break;
1711
 
1712
  case 60:
1713
#line 166 "defparse.y"
1714
    { (yyval.id) =  0; }
1715
    break;
1716
 
1717
  case 61:
1718
#line 169 "defparse.y"
1719
    { (yyval.number)= (yyvsp[(3) - (3)].number);}
1720
    break;
1721
 
1722
  case 62:
1723
#line 170 "defparse.y"
1724
    { (yyval.number)=-1;}
1725
    break;
1726
 
1727
 
1728
/* Line 1267 of yacc.c.  */
1729
#line 1730 "defparse.c"
1730
      default: break;
1731
    }
1732
  YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc);
1733
 
1734
  YYPOPSTACK (yylen);
1735
  yylen = 0;
1736
  YY_STACK_PRINT (yyss, yyssp);
1737
 
1738
  *++yyvsp = yyval;
1739
 
1740
 
1741
  /* Now `shift' the result of the reduction.  Determine what state
1742
     that goes to, based on the state we popped back to and the rule
1743
     number reduced by.  */
1744
 
1745
  yyn = yyr1[yyn];
1746
 
1747
  yystate = yypgoto[yyn - YYNTOKENS] + *yyssp;
1748
  if (0 <= yystate && yystate <= YYLAST && yycheck[yystate] == *yyssp)
1749
    yystate = yytable[yystate];
1750
  else
1751
    yystate = yydefgoto[yyn - YYNTOKENS];
1752
 
1753
  goto yynewstate;
1754
 
1755
 
1756
/*------------------------------------.
1757
| yyerrlab -- here on detecting error |
1758
`------------------------------------*/
1759
yyerrlab:
1760
  /* If not already recovering from an error, report this error.  */
1761
  if (!yyerrstatus)
1762
    {
1763
      ++yynerrs;
1764
#if ! YYERROR_VERBOSE
1765
      yyerror (YY_("syntax error"));
1766
#else
1767
      {
1768
        YYSIZE_T yysize = yysyntax_error (0, yystate, yychar);
1769
        if (yymsg_alloc < yysize && yymsg_alloc < YYSTACK_ALLOC_MAXIMUM)
1770
          {
1771
            YYSIZE_T yyalloc = 2 * yysize;
1772
            if (! (yysize <= yyalloc && yyalloc <= YYSTACK_ALLOC_MAXIMUM))
1773
              yyalloc = YYSTACK_ALLOC_MAXIMUM;
1774
            if (yymsg != yymsgbuf)
1775
              YYSTACK_FREE (yymsg);
1776
            yymsg = (char *) YYSTACK_ALLOC (yyalloc);
1777
            if (yymsg)
1778
              yymsg_alloc = yyalloc;
1779
            else
1780
              {
1781
                yymsg = yymsgbuf;
1782
                yymsg_alloc = sizeof yymsgbuf;
1783
              }
1784
          }
1785
 
1786
        if (0 < yysize && yysize <= yymsg_alloc)
1787
          {
1788
            (void) yysyntax_error (yymsg, yystate, yychar);
1789
            yyerror (yymsg);
1790
          }
1791
        else
1792
          {
1793
            yyerror (YY_("syntax error"));
1794
            if (yysize != 0)
1795
              goto yyexhaustedlab;
1796
          }
1797
      }
1798
#endif
1799
    }
1800
 
1801
 
1802
 
1803
  if (yyerrstatus == 3)
1804
    {
1805
      /* If just tried and failed to reuse look-ahead token after an
1806
         error, discard it.  */
1807
 
1808
      if (yychar <= YYEOF)
1809
        {
1810
          /* Return failure if at end of input.  */
1811
          if (yychar == YYEOF)
1812
            YYABORT;
1813
        }
1814
      else
1815
        {
1816
          yydestruct ("Error: discarding",
1817
                      yytoken, &yylval);
1818
          yychar = YYEMPTY;
1819
        }
1820
    }
1821
 
1822
  /* Else will try to reuse look-ahead token after shifting the error
1823
     token.  */
1824
  goto yyerrlab1;
1825
 
1826
 
1827
/*---------------------------------------------------.
1828
| yyerrorlab -- error raised explicitly by YYERROR.  |
1829
`---------------------------------------------------*/
1830
yyerrorlab:
1831
 
1832
  /* Pacify compilers like GCC when the user code never invokes
1833
     YYERROR and the label yyerrorlab therefore never appears in user
1834
     code.  */
1835
  if (/*CONSTCOND*/ 0)
1836
     goto yyerrorlab;
1837
 
1838
  /* Do not reclaim the symbols of the rule which action triggered
1839
     this YYERROR.  */
1840
  YYPOPSTACK (yylen);
1841
  yylen = 0;
1842
  YY_STACK_PRINT (yyss, yyssp);
1843
  yystate = *yyssp;
1844
  goto yyerrlab1;
1845
 
1846
 
1847
/*-------------------------------------------------------------.
1848
| yyerrlab1 -- common code for both syntax error and YYERROR.  |
1849
`-------------------------------------------------------------*/
1850
yyerrlab1:
1851
  yyerrstatus = 3;      /* Each real token shifted decrements this.  */
1852
 
1853
  for (;;)
1854
    {
1855
      yyn = yypact[yystate];
1856
      if (yyn != YYPACT_NINF)
1857
        {
1858
          yyn += YYTERROR;
1859
          if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYTERROR)
1860
            {
1861
              yyn = yytable[yyn];
1862
              if (0 < yyn)
1863
                break;
1864
            }
1865
        }
1866
 
1867
      /* Pop the current state because it cannot handle the error token.  */
1868
      if (yyssp == yyss)
1869
        YYABORT;
1870
 
1871
 
1872
      yydestruct ("Error: popping",
1873
                  yystos[yystate], yyvsp);
1874
      YYPOPSTACK (1);
1875
      yystate = *yyssp;
1876
      YY_STACK_PRINT (yyss, yyssp);
1877
    }
1878
 
1879
  if (yyn == YYFINAL)
1880
    YYACCEPT;
1881
 
1882
  *++yyvsp = yylval;
1883
 
1884
 
1885
  /* Shift the error token.  */
1886
  YY_SYMBOL_PRINT ("Shifting", yystos[yyn], yyvsp, yylsp);
1887
 
1888
  yystate = yyn;
1889
  goto yynewstate;
1890
 
1891
 
1892
/*-------------------------------------.
1893
| yyacceptlab -- YYACCEPT comes here.  |
1894
`-------------------------------------*/
1895
yyacceptlab:
1896
  yyresult = 0;
1897
  goto yyreturn;
1898
 
1899
/*-----------------------------------.
1900
| yyabortlab -- YYABORT comes here.  |
1901
`-----------------------------------*/
1902
yyabortlab:
1903
  yyresult = 1;
1904
  goto yyreturn;
1905
 
1906
#ifndef yyoverflow
1907
/*-------------------------------------------------.
1908
| yyexhaustedlab -- memory exhaustion comes here.  |
1909
`-------------------------------------------------*/
1910
yyexhaustedlab:
1911
  yyerror (YY_("memory exhausted"));
1912
  yyresult = 2;
1913
  /* Fall through.  */
1914
#endif
1915
 
1916
yyreturn:
1917
  if (yychar != YYEOF && yychar != YYEMPTY)
1918
     yydestruct ("Cleanup: discarding lookahead",
1919
                 yytoken, &yylval);
1920
  /* Do not reclaim the symbols of the rule which action triggered
1921
     this YYABORT or YYACCEPT.  */
1922
  YYPOPSTACK (yylen);
1923
  YY_STACK_PRINT (yyss, yyssp);
1924
  while (yyssp != yyss)
1925
    {
1926
      yydestruct ("Cleanup: popping",
1927
                  yystos[*yyssp], yyvsp);
1928
      YYPOPSTACK (1);
1929
    }
1930
#ifndef yyoverflow
1931
  if (yyss != yyssa)
1932
    YYSTACK_FREE (yyss);
1933
#endif
1934
#if YYERROR_VERBOSE
1935
  if (yymsg != yymsgbuf)
1936
    YYSTACK_FREE (yymsg);
1937
#endif
1938
  /* Make sure YYID is used.  */
1939
  return YYID (yyresult);
1940
}
1941
 
1942
 
1943
 

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.