9cf10d2a0e7cc868639ca4187c4e4419b5f6ece8
[reactos.git] / reactos / tools / widl / parser.tab.c
1 /* A Bison parser, made by GNU Bison 2.1. */
2
3 /* Skeleton parser for Yacc-like parsing with Bison,
4 Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc.
5
6 This program is free software; you can redistribute it and/or modify
7 it under the terms of the GNU General Public License as published by
8 the Free Software Foundation; either version 2, or (at your option)
9 any later version.
10
11 This program is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 GNU General Public License for more details.
15
16 You should have received a copy of the GNU General Public License
17 along with this program; if not, write to the Free Software
18 Foundation, Inc., 51 Franklin Street, Fifth Floor,
19 Boston, MA 02110-1301, USA. */
20
21 /* As a special exception, when this file is copied by Bison into a
22 Bison output file, you may use that output file without restriction.
23 This special exception was added by the Free Software Foundation
24 in version 1.24 of Bison. */
25
26 /* Written by Richard Stallman by simplifying the original so called
27 ``semantic'' parser. */
28
29 /* All symbols defined below should begin with yy or YY, to avoid
30 infringing on user name space. This should be done even for local
31 variables, as they might otherwise be expanded by user macros.
32 There are some unavoidable exceptions within include files to
33 define necessary library symbols; they are noted "INFRINGES ON
34 USER NAME SPACE" below. */
35
36 /* Identify Bison output. */
37 #define YYBISON 1
38
39 /* Bison version. */
40 #define YYBISON_VERSION "2.1"
41
42 /* Skeleton name. */
43 #define YYSKELETON_NAME "yacc.c"
44
45 /* Pure parsers. */
46 #define YYPURE 0
47
48 /* Using locations. */
49 #define YYLSP_NEEDED 0
50
51 /* Substitute the variable and function names. */
52 #define yyparse parser_parse
53 #define yylex parser_lex
54 #define yyerror parser_error
55 #define yylval parser_lval
56 #define yychar parser_char
57 #define yydebug parser_debug
58 #define yynerrs parser_nerrs
59
60
61 /* Tokens. */
62 #ifndef YYTOKENTYPE
63 # define YYTOKENTYPE
64 /* Put the tokens into the symbol table, so that GDB and other debuggers
65 know about them. */
66 enum yytokentype {
67 aIDENTIFIER = 258,
68 aKNOWNTYPE = 259,
69 aNUM = 260,
70 aHEXNUM = 261,
71 aDOUBLE = 262,
72 aSTRING = 263,
73 aUUID = 264,
74 aEOF = 265,
75 SHL = 266,
76 SHR = 267,
77 tAGGREGATABLE = 268,
78 tALLOCATE = 269,
79 tAPPOBJECT = 270,
80 tASYNC = 271,
81 tASYNCUUID = 272,
82 tAUTOHANDLE = 273,
83 tBINDABLE = 274,
84 tBOOLEAN = 275,
85 tBROADCAST = 276,
86 tBYTE = 277,
87 tBYTECOUNT = 278,
88 tCALLAS = 279,
89 tCALLBACK = 280,
90 tCASE = 281,
91 tCDECL = 282,
92 tCHAR = 283,
93 tCOCLASS = 284,
94 tCODE = 285,
95 tCOMMSTATUS = 286,
96 tCONST = 287,
97 tCONTEXTHANDLE = 288,
98 tCONTEXTHANDLENOSERIALIZE = 289,
99 tCONTEXTHANDLESERIALIZE = 290,
100 tCONTROL = 291,
101 tCPPQUOTE = 292,
102 tDEFAULT = 293,
103 tDEFAULTCOLLELEM = 294,
104 tDEFAULTVALUE = 295,
105 tDEFAULTVTABLE = 296,
106 tDISPLAYBIND = 297,
107 tDISPINTERFACE = 298,
108 tDLLNAME = 299,
109 tDOUBLE = 300,
110 tDUAL = 301,
111 tENDPOINT = 302,
112 tENTRY = 303,
113 tENUM = 304,
114 tERRORSTATUST = 305,
115 tEXPLICITHANDLE = 306,
116 tEXTERN = 307,
117 tFALSE = 308,
118 tFLOAT = 309,
119 tHANDLE = 310,
120 tHANDLET = 311,
121 tHELPCONTEXT = 312,
122 tHELPFILE = 313,
123 tHELPSTRING = 314,
124 tHELPSTRINGCONTEXT = 315,
125 tHELPSTRINGDLL = 316,
126 tHIDDEN = 317,
127 tHYPER = 318,
128 tID = 319,
129 tIDEMPOTENT = 320,
130 tIIDIS = 321,
131 tIMMEDIATEBIND = 322,
132 tIMPLICITHANDLE = 323,
133 tIMPORT = 324,
134 tIMPORTLIB = 325,
135 tIN = 326,
136 tINLINE = 327,
137 tINPUTSYNC = 328,
138 tINT = 329,
139 tINT64 = 330,
140 tINTERFACE = 331,
141 tLCID = 332,
142 tLENGTHIS = 333,
143 tLIBRARY = 334,
144 tLOCAL = 335,
145 tLONG = 336,
146 tMETHODS = 337,
147 tMODULE = 338,
148 tNONBROWSABLE = 339,
149 tNONCREATABLE = 340,
150 tNONEXTENSIBLE = 341,
151 tOBJECT = 342,
152 tODL = 343,
153 tOLEAUTOMATION = 344,
154 tOPTIONAL = 345,
155 tOUT = 346,
156 tPOINTERDEFAULT = 347,
157 tPROPERTIES = 348,
158 tPROPGET = 349,
159 tPROPPUT = 350,
160 tPROPPUTREF = 351,
161 tPTR = 352,
162 tPUBLIC = 353,
163 tRANGE = 354,
164 tREADONLY = 355,
165 tREF = 356,
166 tREQUESTEDIT = 357,
167 tRESTRICTED = 358,
168 tRETVAL = 359,
169 tSAFEARRAY = 360,
170 tSHORT = 361,
171 tSIGNED = 362,
172 tSINGLE = 363,
173 tSIZEIS = 364,
174 tSIZEOF = 365,
175 tSMALL = 366,
176 tSOURCE = 367,
177 tSTDCALL = 368,
178 tSTRICTCONTEXTHANDLE = 369,
179 tSTRING = 370,
180 tSTRUCT = 371,
181 tSWITCH = 372,
182 tSWITCHIS = 373,
183 tSWITCHTYPE = 374,
184 tTRANSMITAS = 375,
185 tTRUE = 376,
186 tTYPEDEF = 377,
187 tUNION = 378,
188 tUNIQUE = 379,
189 tUNSIGNED = 380,
190 tUUID = 381,
191 tV1ENUM = 382,
192 tVARARG = 383,
193 tVERSION = 384,
194 tVOID = 385,
195 tWCHAR = 386,
196 tWIREMARSHAL = 387,
197 CAST = 388,
198 PPTR = 389,
199 NEG = 390,
200 ADDRESSOF = 391
201 };
202 #endif
203 /* Tokens. */
204 #define aIDENTIFIER 258
205 #define aKNOWNTYPE 259
206 #define aNUM 260
207 #define aHEXNUM 261
208 #define aDOUBLE 262
209 #define aSTRING 263
210 #define aUUID 264
211 #define aEOF 265
212 #define SHL 266
213 #define SHR 267
214 #define tAGGREGATABLE 268
215 #define tALLOCATE 269
216 #define tAPPOBJECT 270
217 #define tASYNC 271
218 #define tASYNCUUID 272
219 #define tAUTOHANDLE 273
220 #define tBINDABLE 274
221 #define tBOOLEAN 275
222 #define tBROADCAST 276
223 #define tBYTE 277
224 #define tBYTECOUNT 278
225 #define tCALLAS 279
226 #define tCALLBACK 280
227 #define tCASE 281
228 #define tCDECL 282
229 #define tCHAR 283
230 #define tCOCLASS 284
231 #define tCODE 285
232 #define tCOMMSTATUS 286
233 #define tCONST 287
234 #define tCONTEXTHANDLE 288
235 #define tCONTEXTHANDLENOSERIALIZE 289
236 #define tCONTEXTHANDLESERIALIZE 290
237 #define tCONTROL 291
238 #define tCPPQUOTE 292
239 #define tDEFAULT 293
240 #define tDEFAULTCOLLELEM 294
241 #define tDEFAULTVALUE 295
242 #define tDEFAULTVTABLE 296
243 #define tDISPLAYBIND 297
244 #define tDISPINTERFACE 298
245 #define tDLLNAME 299
246 #define tDOUBLE 300
247 #define tDUAL 301
248 #define tENDPOINT 302
249 #define tENTRY 303
250 #define tENUM 304
251 #define tERRORSTATUST 305
252 #define tEXPLICITHANDLE 306
253 #define tEXTERN 307
254 #define tFALSE 308
255 #define tFLOAT 309
256 #define tHANDLE 310
257 #define tHANDLET 311
258 #define tHELPCONTEXT 312
259 #define tHELPFILE 313
260 #define tHELPSTRING 314
261 #define tHELPSTRINGCONTEXT 315
262 #define tHELPSTRINGDLL 316
263 #define tHIDDEN 317
264 #define tHYPER 318
265 #define tID 319
266 #define tIDEMPOTENT 320
267 #define tIIDIS 321
268 #define tIMMEDIATEBIND 322
269 #define tIMPLICITHANDLE 323
270 #define tIMPORT 324
271 #define tIMPORTLIB 325
272 #define tIN 326
273 #define tINLINE 327
274 #define tINPUTSYNC 328
275 #define tINT 329
276 #define tINT64 330
277 #define tINTERFACE 331
278 #define tLCID 332
279 #define tLENGTHIS 333
280 #define tLIBRARY 334
281 #define tLOCAL 335
282 #define tLONG 336
283 #define tMETHODS 337
284 #define tMODULE 338
285 #define tNONBROWSABLE 339
286 #define tNONCREATABLE 340
287 #define tNONEXTENSIBLE 341
288 #define tOBJECT 342
289 #define tODL 343
290 #define tOLEAUTOMATION 344
291 #define tOPTIONAL 345
292 #define tOUT 346
293 #define tPOINTERDEFAULT 347
294 #define tPROPERTIES 348
295 #define tPROPGET 349
296 #define tPROPPUT 350
297 #define tPROPPUTREF 351
298 #define tPTR 352
299 #define tPUBLIC 353
300 #define tRANGE 354
301 #define tREADONLY 355
302 #define tREF 356
303 #define tREQUESTEDIT 357
304 #define tRESTRICTED 358
305 #define tRETVAL 359
306 #define tSAFEARRAY 360
307 #define tSHORT 361
308 #define tSIGNED 362
309 #define tSINGLE 363
310 #define tSIZEIS 364
311 #define tSIZEOF 365
312 #define tSMALL 366
313 #define tSOURCE 367
314 #define tSTDCALL 368
315 #define tSTRICTCONTEXTHANDLE 369
316 #define tSTRING 370
317 #define tSTRUCT 371
318 #define tSWITCH 372
319 #define tSWITCHIS 373
320 #define tSWITCHTYPE 374
321 #define tTRANSMITAS 375
322 #define tTRUE 376
323 #define tTYPEDEF 377
324 #define tUNION 378
325 #define tUNIQUE 379
326 #define tUNSIGNED 380
327 #define tUUID 381
328 #define tV1ENUM 382
329 #define tVARARG 383
330 #define tVERSION 384
331 #define tVOID 385
332 #define tWCHAR 386
333 #define tWIREMARSHAL 387
334 #define CAST 388
335 #define PPTR 389
336 #define NEG 390
337 #define ADDRESSOF 391
338
339
340
341
342 /* Copy the first part of user declarations. */
343 #line 1 "parser.y"
344
345 /*
346 * IDL Compiler
347 *
348 * Copyright 2002 Ove Kaaven
349 *
350 * This library is free software; you can redistribute it and/or
351 * modify it under the terms of the GNU Lesser General Public
352 * License as published by the Free Software Foundation; either
353 * version 2.1 of the License, or (at your option) any later version.
354 *
355 * This library is distributed in the hope that it will be useful,
356 * but WITHOUT ANY WARRANTY; without even the implied warranty of
357 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
358 * Lesser General Public License for more details.
359 *
360 * You should have received a copy of the GNU Lesser General Public
361 * License along with this library; if not, write to the Free Software
362 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
363 */
364
365 #include "config.h"
366
367 #include <stdio.h>
368 #include <stdlib.h>
369 #include <stdarg.h>
370 #include <assert.h>
371 #include <ctype.h>
372 #include <string.h>
373 #ifdef HAVE_ALLOCA_H
374 #include <alloca.h>
375 #endif
376
377 #include "widl.h"
378 #include "utils.h"
379 #include "parser.h"
380 #include "header.h"
381 #include "typelib.h"
382 #include "typegen.h"
383
384 #if defined(YYBYACC)
385 /* Berkeley yacc (byacc) doesn't seem to know about these */
386 /* Some *BSD supplied versions do define these though */
387 # ifndef YYEMPTY
388 # define YYEMPTY (-1) /* Empty lookahead value of yychar */
389 # endif
390 # ifndef YYLEX
391 # define YYLEX yylex()
392 # endif
393
394 #elif defined(YYBISON)
395 /* Bison was used for original development */
396 /* #define YYEMPTY -2 */
397 /* #define YYLEX yylex() */
398
399 #else
400 /* No yacc we know yet */
401 # if !defined(YYEMPTY) || !defined(YYLEX)
402 # error Yacc version/type unknown. This version needs to be verified for settings of YYEMPTY and YYLEX.
403 # elif defined(__GNUC__) /* gcc defines the #warning directive */
404 # warning Yacc version/type unknown. It defines YYEMPTY and YYLEX, but is not tested
405 /* #else we just take a chance that it works... */
406 # endif
407 #endif
408
409 unsigned char pointer_default = RPC_FC_UP;
410
411 typedef struct list typelist_t;
412 struct typenode {
413 type_t *type;
414 struct list entry;
415 };
416
417 typelist_t incomplete_types = LIST_INIT(incomplete_types);
418
419 static void add_incomplete(type_t *t);
420 static void fix_incomplete(void);
421
422 static str_list_t *append_str(str_list_t *list, char *str);
423 static attr_list_t *append_attr(attr_list_t *list, attr_t *attr);
424 static attr_t *make_attr(enum attr_type type);
425 static attr_t *make_attrv(enum attr_type type, unsigned long val);
426 static attr_t *make_attrp(enum attr_type type, void *val);
427 static expr_t *make_expr(enum expr_type type);
428 static expr_t *make_exprl(enum expr_type type, long val);
429 static expr_t *make_exprd(enum expr_type type, double val);
430 static expr_t *make_exprs(enum expr_type type, char *val);
431 static expr_t *make_exprt(enum expr_type type, type_t *tref, expr_t *expr);
432 static expr_t *make_expr1(enum expr_type type, expr_t *expr);
433 static expr_t *make_expr2(enum expr_type type, expr_t *exp1, expr_t *exp2);
434 static expr_t *make_expr3(enum expr_type type, expr_t *expr1, expr_t *expr2, expr_t *expr3);
435 static type_t *make_type(unsigned char type, type_t *ref);
436 static expr_list_t *append_expr(expr_list_t *list, expr_t *expr);
437 static array_dims_t *append_array(array_dims_t *list, expr_t *expr);
438 static void set_type(var_t *v, type_t *type, int ptr_level, array_dims_t *arr, int top);
439 static ifref_list_t *append_ifref(ifref_list_t *list, ifref_t *iface);
440 static ifref_t *make_ifref(type_t *iface);
441 static var_list_t *append_var(var_list_t *list, var_t *var);
442 static var_t *make_var(char *name);
443 static pident_list_t *append_pident(pident_list_t *list, pident_t *p);
444 static pident_t *make_pident(var_t *var);
445 static func_list_t *append_func(func_list_t *list, func_t *func);
446 static func_t *make_func(var_t *def, var_list_t *args);
447 static type_t *make_class(char *name);
448 static type_t *make_safearray(type_t *type);
449 static type_t *make_builtin(char *name);
450 static type_t *make_int(int sign);
451
452 static type_t *reg_type(type_t *type, const char *name, int t);
453 static type_t *reg_typedefs(type_t *type, var_list_t *names, attr_list_t *attrs);
454 static type_t *find_type(const char *name, int t);
455 static type_t *find_type2(char *name, int t);
456 static type_t *get_type(unsigned char type, char *name, int t);
457 static type_t *get_typev(unsigned char type, var_t *name, int t);
458 static int get_struct_type(var_list_t *fields);
459
460 static var_t *reg_const(var_t *var);
461 static var_t *find_const(char *name, int f);
462
463 static void write_libid(const char *name, const attr_list_t *attr);
464 static void write_clsid(type_t *cls);
465 static void write_diid(type_t *iface);
466 static void write_iid(type_t *iface);
467
468 static int compute_method_indexes(type_t *iface);
469 static char *gen_name(void);
470 static void process_typedefs(var_list_t *names);
471 static void check_arg(var_t *arg);
472 static void check_all_user_types(ifref_list_t *ifaces);
473
474 #define tsENUM 1
475 #define tsSTRUCT 2
476 #define tsUNION 3
477
478
479
480 /* Enabling traces. */
481 #ifndef YYDEBUG
482 # define YYDEBUG 0
483 #endif
484
485 /* Enabling verbose error messages. */
486 #ifdef YYERROR_VERBOSE
487 # undef YYERROR_VERBOSE
488 # define YYERROR_VERBOSE 1
489 #else
490 # define YYERROR_VERBOSE 0
491 #endif
492
493 /* Enabling the token table. */
494 #ifndef YYTOKEN_TABLE
495 # define YYTOKEN_TABLE 0
496 #endif
497
498 #if ! defined (YYSTYPE) && ! defined (YYSTYPE_IS_DECLARED)
499 #line 136 "parser.y"
500 typedef union YYSTYPE {
501 attr_t *attr;
502 attr_list_t *attr_list;
503 str_list_t *str_list;
504 expr_t *expr;
505 expr_list_t *expr_list;
506 array_dims_t *array_dims;
507 type_t *type;
508 var_t *var;
509 var_list_t *var_list;
510 pident_t *pident;
511 pident_list_t *pident_list;
512 func_t *func;
513 func_list_t *func_list;
514 ifref_t *ifref;
515 ifref_list_t *ifref_list;
516 char *str;
517 UUID *uuid;
518 unsigned int num;
519 double dbl;
520 interface_info_t ifinfo;
521 } YYSTYPE;
522 /* Line 196 of yacc.c. */
523 #line 524 "parser.tab.c"
524 # define yystype YYSTYPE /* obsolescent; will be withdrawn */
525 # define YYSTYPE_IS_DECLARED 1
526 # define YYSTYPE_IS_TRIVIAL 1
527 #endif
528
529
530
531 /* Copy the second part of user declarations. */
532
533
534 /* Line 219 of yacc.c. */
535 #line 536 "parser.tab.c"
536
537 #if ! defined (YYSIZE_T) && defined (__SIZE_TYPE__)
538 # define YYSIZE_T __SIZE_TYPE__
539 #endif
540 #if ! defined (YYSIZE_T) && defined (size_t)
541 # define YYSIZE_T size_t
542 #endif
543 #if ! defined (YYSIZE_T) && (defined (__STDC__) || defined (__cplusplus))
544 # include <stddef.h> /* INFRINGES ON USER NAME SPACE */
545 # define YYSIZE_T size_t
546 #endif
547 #if ! defined (YYSIZE_T)
548 # define YYSIZE_T unsigned int
549 #endif
550
551 #ifndef YY_
552 # if YYENABLE_NLS
553 # if ENABLE_NLS
554 # include <libintl.h> /* INFRINGES ON USER NAME SPACE */
555 # define YY_(msgid) dgettext ("bison-runtime", msgid)
556 # endif
557 # endif
558 # ifndef YY_
559 # define YY_(msgid) msgid
560 # endif
561 #endif
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 # else
572 # define YYSTACK_ALLOC alloca
573 # if defined (__STDC__) || defined (__cplusplus)
574 # include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
575 # define YYINCLUDED_STDLIB_H
576 # endif
577 # endif
578 # endif
579 # endif
580
581 # ifdef YYSTACK_ALLOC
582 /* Pacify GCC's `empty if-body' warning. */
583 # define YYSTACK_FREE(Ptr) do { /* empty */; } while (0)
584 # ifndef YYSTACK_ALLOC_MAXIMUM
585 /* The OS might guarantee only one guard page at the bottom of the stack,
586 and a page size can be as small as 4096 bytes. So we cannot safely
587 invoke alloca (N) if N exceeds 4096. Use a slightly smaller number
588 to allow for a few compiler-allocated temporary stack slots. */
589 # define YYSTACK_ALLOC_MAXIMUM 4032 /* reasonable circa 2005 */
590 # endif
591 # else
592 # define YYSTACK_ALLOC YYMALLOC
593 # define YYSTACK_FREE YYFREE
594 # ifndef YYSTACK_ALLOC_MAXIMUM
595 # define YYSTACK_ALLOC_MAXIMUM ((YYSIZE_T) -1)
596 # endif
597 # ifdef __cplusplus
598 extern "C" {
599 # endif
600 # ifndef YYMALLOC
601 # define YYMALLOC malloc
602 # if (! defined (malloc) && ! defined (YYINCLUDED_STDLIB_H) \
603 && (defined (__STDC__) || defined (__cplusplus)))
604 void *malloc (YYSIZE_T); /* INFRINGES ON USER NAME SPACE */
605 # endif
606 # endif
607 # ifndef YYFREE
608 # define YYFREE free
609 # if (! defined (free) && ! defined (YYINCLUDED_STDLIB_H) \
610 && (defined (__STDC__) || defined (__cplusplus)))
611 void free (void *); /* INFRINGES ON USER NAME SPACE */
612 # endif
613 # endif
614 # ifdef __cplusplus
615 }
616 # endif
617 # endif
618 #endif /* ! defined (yyoverflow) || YYERROR_VERBOSE */
619
620
621 #if (! defined (yyoverflow) \
622 && (! defined (__cplusplus) \
623 || (defined (YYSTYPE_IS_TRIVIAL) && YYSTYPE_IS_TRIVIAL)))
624
625 /* A type that is properly aligned for any stack member. */
626 union yyalloc
627 {
628 short int yyss;
629 YYSTYPE yyvs;
630 };
631
632 /* The size of the maximum gap between one aligned stack and the next. */
633 # define YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1)
634
635 /* The size of an array large to enough to hold all stacks, each with
636 N elements. */
637 # define YYSTACK_BYTES(N) \
638 ((N) * (sizeof (short int) + sizeof (YYSTYPE)) \
639 + YYSTACK_GAP_MAXIMUM)
640
641 /* Copy COUNT objects from FROM to TO. The source and destination do
642 not overlap. */
643 # ifndef YYCOPY
644 # if defined (__GNUC__) && 1 < __GNUC__
645 # define YYCOPY(To, From, Count) \
646 __builtin_memcpy (To, From, (Count) * sizeof (*(From)))
647 # else
648 # define YYCOPY(To, From, Count) \
649 do \
650 { \
651 YYSIZE_T yyi; \
652 for (yyi = 0; yyi < (Count); yyi++) \
653 (To)[yyi] = (From)[yyi]; \
654 } \
655 while (0)
656 # endif
657 # endif
658
659 /* Relocate STACK from its old location to the new one. The
660 local variables YYSIZE and YYSTACKSIZE give the old and new number of
661 elements in the stack, and YYPTR gives the new location of the
662 stack. Advance YYPTR to a properly aligned location for the next
663 stack. */
664 # define YYSTACK_RELOCATE(Stack) \
665 do \
666 { \
667 YYSIZE_T yynewbytes; \
668 YYCOPY (&yyptr->Stack, Stack, yysize); \
669 Stack = &yyptr->Stack; \
670 yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \
671 yyptr += yynewbytes / sizeof (*yyptr); \
672 } \
673 while (0)
674
675 #endif
676
677 #if defined (__STDC__) || defined (__cplusplus)
678 typedef signed char yysigned_char;
679 #else
680 typedef short int yysigned_char;
681 #endif
682
683 /* YYFINAL -- State number of the termination state. */
684 #define YYFINAL 3
685 /* YYLAST -- Last index in YYTABLE. */
686 #define YYLAST 1019
687
688 /* YYNTOKENS -- Number of terminals. */
689 #define YYNTOKENS 156
690 /* YYNNTS -- Number of nonterminals. */
691 #define YYNNTS 76
692 /* YYNRULES -- Number of rules. */
693 #define YYNRULES 272
694 /* YYNRULES -- Number of states. */
695 #define YYNSTATES 500
696
697 /* YYTRANSLATE(YYLEX) -- Bison symbol number corresponding to YYLEX. */
698 #define YYUNDEFTOK 2
699 #define YYMAXUTOK 391
700
701 #define YYTRANSLATE(YYX) \
702 ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK)
703
704 /* YYTRANSLATE[YYLEX] -- Bison symbol number corresponding to YYLEX. */
705 static const unsigned char yytranslate[] =
706 {
707 0, 2, 2, 2, 2, 2, 2, 2, 2, 2,
708 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
709 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
710 2, 2, 2, 2, 2, 2, 2, 2, 137, 2,
711 148, 149, 140, 139, 133, 138, 155, 141, 2, 2,
712 2, 2, 2, 2, 2, 2, 2, 2, 135, 147,
713 2, 154, 2, 134, 2, 2, 2, 2, 2, 2,
714 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
715 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
716 2, 152, 2, 153, 2, 2, 2, 2, 2, 2,
717 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
718 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
719 2, 2, 2, 150, 136, 151, 142, 2, 2, 2,
720 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
721 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
722 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
723 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
724 2, 2, 2, 2, 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, 2, 2, 2, 2, 2, 2,
728 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
729 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
730 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
731 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
732 2, 2, 2, 2, 2, 2, 1, 2, 3, 4,
733 5, 6, 7, 8, 9, 10, 11, 12, 13, 14,
734 15, 16, 17, 18, 19, 20, 21, 22, 23, 24,
735 25, 26, 27, 28, 29, 30, 31, 32, 33, 34,
736 35, 36, 37, 38, 39, 40, 41, 42, 43, 44,
737 45, 46, 47, 48, 49, 50, 51, 52, 53, 54,
738 55, 56, 57, 58, 59, 60, 61, 62, 63, 64,
739 65, 66, 67, 68, 69, 70, 71, 72, 73, 74,
740 75, 76, 77, 78, 79, 80, 81, 82, 83, 84,
741 85, 86, 87, 88, 89, 90, 91, 92, 93, 94,
742 95, 96, 97, 98, 99, 100, 101, 102, 103, 104,
743 105, 106, 107, 108, 109, 110, 111, 112, 113, 114,
744 115, 116, 117, 118, 119, 120, 121, 122, 123, 124,
745 125, 126, 127, 128, 129, 130, 131, 132, 143, 144,
746 145, 146
747 };
748
749 #if YYDEBUG
750 /* YYPRHS[YYN] -- Index of the first RHS symbol of rule number YYN in
751 YYRHS. */
752 static const unsigned short int yyprhs[] =
753 {
754 0, 0, 3, 5, 6, 9, 12, 16, 19, 22,
755 25, 28, 29, 32, 35, 39, 42, 45, 48, 51,
756 52, 56, 59, 61, 64, 66, 69, 72, 74, 77,
757 80, 83, 88, 92, 96, 101, 104, 108, 112, 113,
758 115, 117, 119, 123, 125, 130, 134, 141, 147, 148,
759 152, 156, 158, 162, 167, 168, 170, 174, 176, 180,
760 185, 187, 191, 192, 194, 196, 198, 200, 202, 207,
761 212, 214, 216, 218, 220, 222, 224, 229, 234, 236,
762 238, 243, 245, 250, 255, 260, 262, 264, 269, 274,
763 279, 284, 289, 291, 296, 298, 303, 305, 311, 313,
764 315, 320, 322, 324, 326, 328, 330, 332, 334, 336,
765 338, 343, 345, 347, 349, 351, 358, 360, 362, 364,
766 366, 371, 373, 375, 377, 382, 387, 392, 397, 399,
767 401, 406, 411, 413, 415, 417, 418, 420, 421, 424,
768 429, 433, 439, 440, 443, 445, 447, 451, 455, 457,
769 463, 465, 469, 470, 472, 474, 476, 478, 480, 482,
770 484, 490, 494, 498, 502, 506, 510, 514, 518, 522,
771 525, 528, 531, 534, 539, 544, 548, 550, 554, 556,
772 561, 562, 565, 568, 572, 575, 577, 582, 590, 591,
773 593, 594, 596, 598, 600, 602, 604, 606, 608, 611,
774 614, 616, 618, 620, 622, 624, 626, 628, 629, 631,
775 633, 636, 638, 641, 644, 646, 648, 651, 654, 657,
776 662, 663, 666, 669, 672, 675, 678, 681, 685, 688,
777 692, 698, 704, 705, 708, 711, 714, 717, 723, 731,
778 733, 736, 739, 742, 745, 748, 753, 756, 759, 761,
779 763, 767, 769, 773, 775, 777, 779, 785, 787, 789,
780 791, 794, 796, 799, 801, 804, 806, 809, 814, 819,
781 825, 836, 838
782 };
783
784 /* YYRHS -- A `-1'-separated list of the rules' RHS. */
785 static const short int yyrhs[] =
786 {
787 157, 0, -1, 158, -1, -1, 158, 219, -1, 158,
788 218, -1, 158, 205, 147, -1, 158, 207, -1, 158,
789 222, -1, 158, 168, -1, 158, 161, -1, -1, 159,
790 219, -1, 159, 218, -1, 159, 205, 147, -1, 159,
791 207, -1, 159, 222, -1, 159, 161, -1, 159, 165,
792 -1, -1, 160, 198, 147, -1, 160, 161, -1, 147,
793 -1, 184, 147, -1, 162, -1, 188, 147, -1, 194,
794 147, -1, 164, -1, 227, 147, -1, 229, 147, -1,
795 230, 147, -1, 37, 148, 8, 149, -1, 69, 8,
796 147, -1, 163, 159, 10, -1, 70, 148, 8, 149,
797 -1, 79, 3, -1, 176, 166, 150, -1, 167, 159,
798 151, -1, -1, 171, -1, 130, -1, 172, -1, 171,
799 133, 172, -1, 170, -1, 176, 228, 224, 173, -1,
800 228, 224, 173, -1, 176, 228, 224, 148, 169, 149,
801 -1, 228, 224, 148, 169, 149, -1, -1, 152, 174,
802 153, -1, 152, 140, 153, -1, 190, -1, 174, 133,
803 191, -1, 174, 153, 152, 191, -1, -1, 176, -1,
804 152, 177, 153, -1, 179, -1, 177, 133, 179, -1,
805 177, 153, 152, 179, -1, 8, -1, 178, 133, 8,
806 -1, -1, 13, -1, 15, -1, 16, -1, 18, -1,
807 19, -1, 24, 148, 201, 149, -1, 26, 148, 192,
808 149, -1, 33, -1, 34, -1, 35, -1, 36, -1,
809 38, -1, 39, -1, 40, 148, 193, 149, -1, 40,
810 148, 8, 149, -1, 41, -1, 42, -1, 44, 148,
811 8, 149, -1, 46, -1, 47, 148, 178, 149, -1,
812 48, 148, 8, 149, -1, 48, 148, 193, 149, -1,
813 51, -1, 55, -1, 57, 148, 193, 149, -1, 58,
814 148, 8, 149, -1, 59, 148, 8, 149, -1, 60,
815 148, 193, 149, -1, 61, 148, 8, 149, -1, 62,
816 -1, 64, 148, 193, 149, -1, 65, -1, 66, 148,
817 191, 149, -1, 67, -1, 68, 148, 56, 3, 149,
818 -1, 71, -1, 73, -1, 78, 148, 189, 149, -1,
819 80, -1, 84, -1, 85, -1, 86, -1, 87, -1,
820 88, -1, 89, -1, 90, -1, 91, -1, 92, 148,
821 226, 149, -1, 94, -1, 95, -1, 96, -1, 98,
822 -1, 99, 148, 193, 133, 193, 149, -1, 100, -1,
823 102, -1, 103, -1, 104, -1, 109, 148, 189, 149,
824 -1, 112, -1, 114, -1, 115, -1, 118, 148, 191,
825 149, -1, 119, 148, 228, 149, -1, 120, 148, 228,
826 149, -1, 126, 148, 180, 149, -1, 127, -1, 128,
827 -1, 129, 148, 231, 149, -1, 132, 148, 228, 149,
828 -1, 226, -1, 9, -1, 8, -1, -1, 113, -1,
829 -1, 182, 183, -1, 26, 191, 135, 196, -1, 38,
830 135, 196, -1, 32, 228, 201, 154, 193, -1, -1,
831 186, 133, -1, 186, -1, 187, -1, 186, 133, 187,
832 -1, 201, 154, 193, -1, 201, -1, 49, 200, 150,
833 185, 151, -1, 190, -1, 189, 133, 190, -1, -1,
834 191, -1, 5, -1, 6, -1, 7, -1, 53, -1,
835 121, -1, 3, -1, 191, 134, 191, 135, 191, -1,
836 191, 136, 191, -1, 191, 137, 191, -1, 191, 139,
837 191, -1, 191, 138, 191, -1, 191, 140, 191, -1,
838 191, 141, 191, -1, 191, 11, 191, -1, 191, 12,
839 191, -1, 142, 191, -1, 138, 191, -1, 137, 191,
840 -1, 140, 191, -1, 148, 228, 149, 191, -1, 110,
841 148, 228, 149, -1, 148, 191, 149, -1, 193, -1,
842 192, 133, 193, -1, 191, -1, 52, 32, 228, 201,
843 -1, -1, 195, 196, -1, 197, 147, -1, 175, 230,
844 147, -1, 176, 147, -1, 147, -1, 175, 228, 224,
845 173, -1, 175, 228, 181, 224, 148, 169, 149, -1,
846 -1, 201, -1, -1, 3, -1, 4, -1, 3, -1,
847 4, -1, 22, -1, 131, -1, 204, -1, 107, 204,
848 -1, 125, 204, -1, 125, -1, 54, -1, 108, -1,
849 45, -1, 20, -1, 50, -1, 56, -1, -1, 74,
850 -1, 74, -1, 106, 203, -1, 111, -1, 81, 203,
851 -1, 63, 203, -1, 75, -1, 28, -1, 29, 3,
852 -1, 29, 4, -1, 176, 205, -1, 206, 150, 208,
853 151, -1, -1, 208, 209, -1, 175, 219, -1, 43,
854 3, -1, 43, 4, -1, 176, 210, -1, 93, 135,
855 -1, 212, 197, 147, -1, 82, 135, -1, 213, 198,
856 147, -1, 211, 150, 212, 213, 151, -1, 211, 150,
857 216, 147, 151, -1, -1, 135, 4, -1, 76, 3,
858 -1, 76, 4, -1, 176, 216, -1, 217, 215, 150,
859 160, 151, -1, 217, 135, 3, 150, 164, 160, 151,
860 -1, 214, -1, 216, 147, -1, 210, 147, -1, 83,
861 3, -1, 83, 4, -1, 176, 220, -1, 221, 150,
862 160, 151, -1, 140, 224, -1, 32, 223, -1, 201,
863 -1, 223, -1, 148, 224, 149, -1, 224, -1, 225,
864 133, 224, -1, 101, -1, 124, -1, 97, -1, 116,
865 200, 150, 195, 151, -1, 130, -1, 4, -1, 202,
866 -1, 32, 228, -1, 188, -1, 49, 3, -1, 227,
867 -1, 116, 3, -1, 230, -1, 123, 3, -1, 105,
868 148, 228, 149, -1, 122, 175, 228, 225, -1, 123,
869 200, 150, 195, 151, -1, 123, 200, 117, 148, 197,
870 149, 199, 150, 182, 151, -1, 5, -1, 5, 155,
871 5, -1
872 };
873
874 /* YYRLINE[YYN] -- source line where rule number YYN was defined. */
875 static const unsigned short int yyrline[] =
876 {
877 0, 286, 286, 295, 296, 297, 298, 302, 307, 308,
878 309, 312, 313, 314, 315, 316, 320, 321, 322, 325,
879 326, 327, 330, 331, 332, 333, 338, 339, 340, 345,
880 346, 353, 355, 358, 361, 364, 366, 371, 374, 375,
881 378, 381, 382, 383, 387, 392, 396, 402, 409, 410,
882 411, 414, 415, 416, 419, 420, 424, 430, 431, 432,
883 435, 436, 439, 440, 441, 442, 443, 444, 445, 446,
884 447, 448, 449, 450, 451, 452, 453, 454, 455, 456,
885 457, 458, 459, 460, 461, 462, 463, 464, 465, 466,
886 467, 468, 469, 470, 471, 472, 473, 474, 475, 476,
887 477, 478, 479, 480, 481, 482, 483, 484, 485, 486,
888 487, 488, 489, 490, 491, 492, 495, 496, 497, 498,
889 499, 500, 501, 502, 503, 504, 505, 506, 507, 508,
890 509, 510, 511, 515, 516, 521, 522, 525, 526, 529,
891 533, 539, 545, 546, 547, 550, 554, 563, 567, 572,
892 581, 582, 595, 596, 599, 600, 601, 602, 603, 604,
893 605, 606, 607, 608, 609, 610, 611, 612, 613, 614,
894 615, 616, 617, 618, 619, 620, 623, 624, 627, 633,
895 638, 639, 642, 643, 644, 645, 648, 656, 668, 669,
896 672, 673, 674, 677, 679, 682, 683, 684, 685, 686,
897 702, 703, 704, 705, 706, 707, 708, 711, 712, 715,
898 716, 717, 718, 719, 720, 721, 724, 725, 731, 740,
899 746, 747, 751, 754, 755, 758, 770, 771, 774, 775,
900 778, 787, 796, 797, 800, 801, 804, 815, 827, 838,
901 842, 843, 846, 847, 850, 855, 861, 862, 865, 866,
902 867, 871, 872, 876, 877, 878, 881, 892, 893, 894,
903 895, 896, 897, 898, 899, 900, 901, 902, 905, 910,
904 915, 932, 933
905 };
906 #endif
907
908 #if YYDEBUG || YYERROR_VERBOSE || YYTOKEN_TABLE
909 /* YYTNAME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM.
910 First, the terminals, then, starting at YYNTOKENS, nonterminals. */
911 static const char *const yytname[] =
912 {
913 "$end", "error", "$undefined", "aIDENTIFIER", "aKNOWNTYPE", "aNUM",
914 "aHEXNUM", "aDOUBLE", "aSTRING", "aUUID", "aEOF", "SHL", "SHR",
915 "tAGGREGATABLE", "tALLOCATE", "tAPPOBJECT", "tASYNC", "tASYNCUUID",
916 "tAUTOHANDLE", "tBINDABLE", "tBOOLEAN", "tBROADCAST", "tBYTE",
917 "tBYTECOUNT", "tCALLAS", "tCALLBACK", "tCASE", "tCDECL", "tCHAR",
918 "tCOCLASS", "tCODE", "tCOMMSTATUS", "tCONST", "tCONTEXTHANDLE",
919 "tCONTEXTHANDLENOSERIALIZE", "tCONTEXTHANDLESERIALIZE", "tCONTROL",
920 "tCPPQUOTE", "tDEFAULT", "tDEFAULTCOLLELEM", "tDEFAULTVALUE",
921 "tDEFAULTVTABLE", "tDISPLAYBIND", "tDISPINTERFACE", "tDLLNAME",
922 "tDOUBLE", "tDUAL", "tENDPOINT", "tENTRY", "tENUM", "tERRORSTATUST",
923 "tEXPLICITHANDLE", "tEXTERN", "tFALSE", "tFLOAT", "tHANDLE", "tHANDLET",
924 "tHELPCONTEXT", "tHELPFILE", "tHELPSTRING", "tHELPSTRINGCONTEXT",
925 "tHELPSTRINGDLL", "tHIDDEN", "tHYPER", "tID", "tIDEMPOTENT", "tIIDIS",
926 "tIMMEDIATEBIND", "tIMPLICITHANDLE", "tIMPORT", "tIMPORTLIB", "tIN",
927 "tINLINE", "tINPUTSYNC", "tINT", "tINT64", "tINTERFACE", "tLCID",
928 "tLENGTHIS", "tLIBRARY", "tLOCAL", "tLONG", "tMETHODS", "tMODULE",
929 "tNONBROWSABLE", "tNONCREATABLE", "tNONEXTENSIBLE", "tOBJECT", "tODL",
930 "tOLEAUTOMATION", "tOPTIONAL", "tOUT", "tPOINTERDEFAULT", "tPROPERTIES",
931 "tPROPGET", "tPROPPUT", "tPROPPUTREF", "tPTR", "tPUBLIC", "tRANGE",
932 "tREADONLY", "tREF", "tREQUESTEDIT", "tRESTRICTED", "tRETVAL",
933 "tSAFEARRAY", "tSHORT", "tSIGNED", "tSINGLE", "tSIZEIS", "tSIZEOF",
934 "tSMALL", "tSOURCE", "tSTDCALL", "tSTRICTCONTEXTHANDLE", "tSTRING",
935 "tSTRUCT", "tSWITCH", "tSWITCHIS", "tSWITCHTYPE", "tTRANSMITAS", "tTRUE",
936 "tTYPEDEF", "tUNION", "tUNIQUE", "tUNSIGNED", "tUUID", "tV1ENUM",
937 "tVARARG", "tVERSION", "tVOID", "tWCHAR", "tWIREMARSHAL", "','", "'?'",
938 "':'", "'|'", "'&'", "'-'", "'+'", "'*'", "'/'", "'~'", "CAST", "PPTR",
939 "NEG", "ADDRESSOF", "';'", "'('", "')'", "'{'", "'}'", "'['", "']'",
940 "'='", "'.'", "$accept", "input", "gbl_statements", "imp_statements",
941 "int_statements", "statement", "cppquote", "import_start", "import",
942 "importlib", "libraryhdr", "library_start", "librarydef", "m_args",
943 "no_args", "args", "arg", "array", "array_list", "m_attributes",
944 "attributes", "attrib_list", "str_list", "attribute", "uuid_string",
945 "callconv", "cases", "case", "constdef", "enums", "enum_list", "enum",
946 "enumdef", "m_exprs", "m_expr", "expr", "expr_list_const", "expr_const",
947 "externdef", "fields", "field", "s_field", "funcdef", "m_ident",
948 "t_ident", "ident", "base_type", "m_int", "int_std", "coclass",
949 "coclasshdr", "coclassdef", "coclass_ints", "coclass_int",
950 "dispinterface", "dispinterfacehdr", "dispint_props", "dispint_meths",
951 "dispinterfacedef", "inherit", "interface", "interfacehdr",
952 "interfacedef", "interfacedec", "module", "modulehdr", "moduledef",
953 "p_ident", "pident", "pident_list", "pointer_type", "structdef", "type",
954 "typedef", "uniondef", "version", 0
955 };
956 #endif
957
958 # ifdef YYPRINT
959 /* YYTOKNUM[YYLEX-NUM] -- Internal token number corresponding to
960 token YYLEX-NUM. */
961 static const unsigned short int yytoknum[] =
962 {
963 0, 256, 257, 258, 259, 260, 261, 262, 263, 264,
964 265, 266, 267, 268, 269, 270, 271, 272, 273, 274,
965 275, 276, 277, 278, 279, 280, 281, 282, 283, 284,
966 285, 286, 287, 288, 289, 290, 291, 292, 293, 294,
967 295, 296, 297, 298, 299, 300, 301, 302, 303, 304,
968 305, 306, 307, 308, 309, 310, 311, 312, 313, 314,
969 315, 316, 317, 318, 319, 320, 321, 322, 323, 324,
970 325, 326, 327, 328, 329, 330, 331, 332, 333, 334,
971 335, 336, 337, 338, 339, 340, 341, 342, 343, 344,
972 345, 346, 347, 348, 349, 350, 351, 352, 353, 354,
973 355, 356, 357, 358, 359, 360, 361, 362, 363, 364,
974 365, 366, 367, 368, 369, 370, 371, 372, 373, 374,
975 375, 376, 377, 378, 379, 380, 381, 382, 383, 384,
976 385, 386, 387, 44, 63, 58, 124, 38, 45, 43,
977 42, 47, 126, 388, 389, 390, 391, 59, 40, 41,
978 123, 125, 91, 93, 61, 46
979 };
980 # endif
981
982 /* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */
983 static const unsigned char yyr1[] =
984 {
985 0, 156, 157, 158, 158, 158, 158, 158, 158, 158,
986 158, 159, 159, 159, 159, 159, 159, 159, 159, 160,
987 160, 160, 161, 161, 161, 161, 161, 161, 161, 161,
988 161, 162, 163, 164, 165, 166, 167, 168, 169, 169,
989 170, 171, 171, 171, 172, 172, 172, 172, 173, 173,
990 173, 174, 174, 174, 175, 175, 176, 177, 177, 177,
991 178, 178, 179, 179, 179, 179, 179, 179, 179, 179,
992 179, 179, 179, 179, 179, 179, 179, 179, 179, 179,
993 179, 179, 179, 179, 179, 179, 179, 179, 179, 179,
994 179, 179, 179, 179, 179, 179, 179, 179, 179, 179,
995 179, 179, 179, 179, 179, 179, 179, 179, 179, 179,
996 179, 179, 179, 179, 179, 179, 179, 179, 179, 179,
997 179, 179, 179, 179, 179, 179, 179, 179, 179, 179,
998 179, 179, 179, 180, 180, 181, 181, 182, 182, 183,
999 183, 184, 185, 185, 185, 186, 186, 187, 187, 188,
1000 189, 189, 190, 190, 191, 191, 191, 191, 191, 191,
1001 191, 191, 191, 191, 191, 191, 191, 191, 191, 191,
1002 191, 191, 191, 191, 191, 191, 192, 192, 193, 194,
1003 195, 195, 196, 196, 196, 196, 197, 198, 199, 199,
1004 200, 200, 200, 201, 201, 202, 202, 202, 202, 202,
1005 202, 202, 202, 202, 202, 202, 202, 203, 203, 204,
1006 204, 204, 204, 204, 204, 204, 205, 205, 206, 207,
1007 208, 208, 209, 210, 210, 211, 212, 212, 213, 213,
1008 214, 214, 215, 215, 216, 216, 217, 218, 218, 218,
1009 219, 219, 220, 220, 221, 222, 223, 223, 224, 224,
1010 224, 225, 225, 226, 226, 226, 227, 228, 228, 228,
1011 228, 228, 228, 228, 228, 228, 228, 228, 229, 230,
1012 230, 231, 231
1013 };
1014
1015 /* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN. */
1016 static const unsigned char yyr2[] =
1017 {
1018 0, 2, 1, 0, 2, 2, 3, 2, 2, 2,
1019 2, 0, 2, 2, 3, 2, 2, 2, 2, 0,
1020 3, 2, 1, 2, 1, 2, 2, 1, 2, 2,
1021 2, 4, 3, 3, 4, 2, 3, 3, 0, 1,
1022 1, 1, 3, 1, 4, 3, 6, 5, 0, 3,
1023 3, 1, 3, 4, 0, 1, 3, 1, 3, 4,
1024 1, 3, 0, 1, 1, 1, 1, 1, 4, 4,
1025 1, 1, 1, 1, 1, 1, 4, 4, 1, 1,
1026 4, 1, 4, 4, 4, 1, 1, 4, 4, 4,
1027 4, 4, 1, 4, 1, 4, 1, 5, 1, 1,
1028 4, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1029 4, 1, 1, 1, 1, 6, 1, 1, 1, 1,
1030 4, 1, 1, 1, 4, 4, 4, 4, 1, 1,
1031 4, 4, 1, 1, 1, 0, 1, 0, 2, 4,
1032 3, 5, 0, 2, 1, 1, 3, 3, 1, 5,
1033 1, 3, 0, 1, 1, 1, 1, 1, 1, 1,
1034 5, 3, 3, 3, 3, 3, 3, 3, 3, 2,
1035 2, 2, 2, 4, 4, 3, 1, 3, 1, 4,
1036 0, 2, 2, 3, 2, 1, 4, 7, 0, 1,
1037 0, 1, 1, 1, 1, 1, 1, 1, 2, 2,
1038 1, 1, 1, 1, 1, 1, 1, 0, 1, 1,
1039 2, 1, 2, 2, 1, 1, 2, 2, 2, 4,
1040 0, 2, 2, 2, 2, 2, 2, 3, 2, 3,
1041 5, 5, 0, 2, 2, 2, 2, 5, 7, 1,
1042 2, 2, 2, 2, 2, 4, 2, 2, 1, 1,
1043 3, 1, 3, 1, 1, 1, 5, 1, 1, 1,
1044 2, 1, 2, 1, 2, 1, 2, 4, 4, 5,
1045 10, 1, 3
1046 };
1047
1048 /* YYDEFACT[STATE-NAME] -- Default rule to reduce with in state
1049 STATE-NUM when YYTABLE doesn't specify something else to do. Zero
1050 means the default is an error. */
1051 static const unsigned short int yydefact[] =
1052 {
1053 3, 0, 2, 1, 0, 0, 0, 0, 190, 0,
1054 0, 0, 190, 54, 190, 22, 62, 10, 24, 11,
1055 27, 11, 9, 0, 0, 0, 0, 0, 0, 7,
1056 0, 0, 239, 0, 232, 5, 4, 0, 8, 0,
1057 0, 0, 216, 217, 258, 204, 195, 215, 0, 203,
1058 190, 205, 201, 206, 207, 209, 214, 207, 0, 207,
1059 0, 202, 211, 190, 190, 200, 257, 196, 261, 259,
1060 197, 263, 0, 265, 0, 223, 224, 191, 192, 0,
1061 0, 0, 234, 235, 0, 0, 55, 0, 63, 64,
1062 65, 66, 67, 0, 0, 70, 71, 72, 73, 74,
1063 75, 0, 78, 79, 0, 81, 0, 0, 85, 86,
1064 0, 0, 0, 0, 0, 92, 0, 94, 0, 96,
1065 0, 98, 99, 0, 101, 102, 103, 104, 105, 106,
1066 107, 108, 109, 0, 111, 112, 113, 255, 114, 0,
1067 116, 253, 117, 118, 119, 0, 121, 122, 123, 0,
1068 0, 0, 254, 0, 128, 129, 0, 0, 0, 57,
1069 132, 0, 0, 0, 0, 0, 218, 225, 236, 244,
1070 23, 25, 26, 6, 220, 241, 0, 240, 0, 0,
1071 19, 28, 29, 30, 260, 262, 208, 213, 212, 0,
1072 210, 198, 264, 266, 199, 193, 194, 0, 0, 142,
1073 0, 32, 180, 0, 0, 180, 0, 0, 0, 0,
1074 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
1075 152, 0, 0, 152, 0, 0, 0, 0, 0, 0,
1076 62, 56, 33, 0, 17, 18, 0, 0, 15, 13,
1077 12, 16, 37, 35, 242, 243, 36, 54, 0, 54,
1078 0, 0, 233, 19, 54, 0, 0, 31, 0, 144,
1079 145, 148, 179, 54, 0, 0, 0, 248, 249, 251,
1080 268, 54, 54, 0, 159, 154, 155, 156, 157, 0,
1081 158, 0, 0, 0, 0, 0, 178, 0, 176, 0,
1082 0, 0, 60, 0, 0, 0, 0, 0, 0, 0,
1083 0, 0, 0, 0, 0, 150, 153, 0, 0, 0,
1084 0, 0, 0, 134, 133, 0, 271, 0, 0, 58,
1085 62, 0, 14, 219, 0, 221, 226, 0, 0, 0,
1086 54, 0, 0, 54, 245, 21, 0, 0, 267, 141,
1087 149, 143, 0, 185, 256, 0, 55, 181, 0, 247,
1088 246, 0, 0, 0, 269, 68, 0, 171, 170, 172,
1089 169, 0, 0, 0, 0, 0, 0, 0, 0, 0,
1090 0, 0, 0, 69, 77, 76, 80, 0, 82, 83,
1091 84, 87, 88, 89, 90, 91, 93, 95, 0, 152,
1092 100, 110, 0, 120, 124, 125, 126, 127, 0, 130,
1093 131, 59, 0, 222, 228, 0, 227, 230, 0, 231,
1094 19, 237, 135, 20, 146, 147, 265, 184, 182, 250,
1095 252, 188, 0, 175, 0, 167, 168, 0, 161, 162,
1096 164, 163, 165, 166, 177, 61, 97, 151, 0, 272,
1097 34, 48, 229, 54, 136, 0, 183, 0, 189, 174,
1098 173, 0, 115, 152, 186, 238, 0, 137, 160, 0,
1099 0, 51, 38, 0, 50, 0, 49, 257, 0, 43,
1100 39, 41, 0, 0, 0, 0, 270, 138, 52, 0,
1101 187, 0, 0, 48, 0, 54, 53, 42, 48, 38,
1102 45, 54, 140, 38, 44, 0, 139, 0, 47, 46
1103 };
1104
1105 /* YYDEFGOTO[NTERM-NUM]. */
1106 static const short int yydefgoto[] =
1107 {
1108 -1, 1, 2, 161, 254, 335, 18, 19, 20, 235,
1109 165, 21, 22, 468, 469, 470, 471, 454, 460, 336,
1110 86, 158, 293, 159, 315, 445, 463, 477, 24, 258,
1111 259, 260, 68, 304, 305, 286, 287, 288, 26, 263,
1112 347, 348, 337, 447, 79, 267, 69, 187, 70, 166,
1113 28, 238, 247, 325, 30, 31, 249, 330, 32, 179,
1114 33, 34, 239, 240, 169, 37, 241, 268, 269, 270,
1115 160, 71, 473, 40, 73, 317
1116 };
1117
1118 /* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing
1119 STATE-NUM. */
1120 #define YYPACT_NINF -446
1121 static const short int yypact[] =
1122 {
1123 -446, 35, 724, -446, 46, 664, -106, 102, 146, 85,
1124 84, 186, 146, -18, 146, -446, 887, -446, -446, -446,
1125 -446, -446, -446, 40, 0, 22, 25, 44, -10, -446,
1126 54, 37, -446, 80, 58, -446, -446, 82, -446, 92,
1127 94, 97, -446, -446, -446, -446, -446, -446, 664, -446,
1128 200, -446, -446, -446, 77, -446, -446, 77, 104, 77,
1129 205, -446, -446, 202, 214, 205, -446, -446, -446, -446,
1130 -446, -446, 227, -446, 248, -446, -446, -446, -446, 110,
1131 664, 118, -446, -446, 117, 664, -446, -96, -446, -446,
1132 -446, -446, -446, 121, 129, -446, -446, -446, -446, -446,
1133 -446, 136, -446, -446, 154, -446, 156, 157, -446, -446,
1134 158, 159, 160, 162, 164, -446, 166, -446, 167, -446,
1135 170, -446, -446, 174, -446, -446, -446, -446, -446, -446,
1136 -446, -446, -446, 175, -446, -446, -446, -446, -446, 177,
1137 -446, -446, -446, -446, -446, 179, -446, -446, -446, 181,
1138 185, 191, -446, 192, -446, -446, 194, 195, -95, -446,
1139 -446, 72, 674, 344, 231, 198, -446, -446, -446, -446,
1140 -446, -446, -446, -446, -446, -446, -42, -446, 270, 199,
1141 -446, -446, -446, -446, -446, 204, -446, -446, -446, 664,
1142 -446, -446, 204, -93, -446, -446, -446, 196, 208, 227,
1143 227, -446, -446, 13, 210, -446, 227, 314, 243, 351,
1144 352, 292, 314, 353, 355, 314, 357, 314, 314, 310,
1145 314, -71, 314, 314, 314, 664, 664, 267, 363, 664,
1146 887, 217, -446, 222, -446, -446, 31, 224, -446, -446,
1147 -446, -446, -446, -446, -446, -446, -446, 131, 237, -63,
1148 226, 225, -446, -446, 663, 228, 314, -446, 223, 249,
1149 -446, 230, -446, -72, -7, 13, 13, -446, -446, -446,
1150 257, -18, -25, 244, -446, -446, -446, -446, -446, 246,
1151 -446, 314, 314, 314, 314, 511, 367, -85, -446, 247,
1152 250, 251, -446, -61, 252, 254, 256, 258, 259, 260,
1153 261, 265, 282, 373, -56, -446, 367, 266, 262, -46,
1154 474, 268, 277, -446, -446, 278, 273, 287, 288, -446,
1155 887, 390, -446, -446, -14, -446, -446, 303, 664, 295,
1156 137, 294, 370, 697, -446, -446, 664, 300, -446, -446,
1157 -446, 227, 314, -446, -446, 664, 308, -446, 311, -446,
1158 -446, 301, 13, 318, -446, -446, 664, -446, -446, -446,
1159 -446, 524, 320, 314, 314, 314, 314, 314, 314, 314,
1160 314, 314, 314, -446, -446, -446, -446, 449, -446, -446,
1161 -446, -446, -446, -446, -446, -446, -446, -446, 323, 314,
1162 -446, -446, 314, -446, -446, -446, -446, -446, 454, -446,
1163 -446, -446, 324, -446, -446, 13, -446, -446, 327, -446,
1164 -446, -446, 365, -446, -446, -446, 333, -446, -446, -446,
1165 -446, 227, 332, -446, 314, -446, -446, 73, 59, 16,
1166 -3, -3, 279, 279, -446, -446, -446, -446, 339, -446,
1167 -446, 338, -446, 785, -446, 13, -446, 342, -446, -446,
1168 -446, 314, -446, 458, -446, -446, 345, -446, 367, 105,
1169 -86, -446, 281, -6, -446, 314, 346, -31, 348, -446,
1170 361, -446, 664, 13, 314, 364, -446, -446, 367, 314,
1171 -446, 421, 13, -20, 542, -84, 367, -446, -17, 281,
1172 -446, -84, -446, 281, -446, 360, -446, 371, -446, -446
1173 };
1174
1175 /* YYPGOTO[NTERM-NUM]. */
1176 static const short int yypgoto[] =
1177 {
1178 -446, -446, -446, 479, -235, 9, -446, -446, 178, -446,
1179 -446, -446, -446, -350, -446, -446, 32, -410, -446, -9,
1180 -2, -446, -446, -207, -446, -446, -446, -446, -446, -446,
1181 -446, 171, 3, 296, -367, -187, -446, -156, -446, 316,
1182 -445, -206, 193, -446, 27, -70, -446, 87, 60, 12,
1183 -446, 520, -446, -446, -13, -446, -446, -446, -446, -446,
1184 -8, -446, 522, 4, -446, -446, 523, 274, -253, -446,
1185 309, 5, -4, -446, 1, -446
1186 };
1187
1188 /* YYTABLE[YYPACT[STATE-NUM]]. What to do in state STATE-NUM. If
1189 positive, shift that token. If negative, reduce the rule which
1190 number is the opposite. If zero, do what YYDEFACT says.
1191 If YYTABLE_NINF, syntax error. */
1192 #define YYTABLE_NINF -192
1193 static const short int yytable[] =
1194 {
1195 23, 72, 197, 41, 85, 25, 36, 39, 363, 364,
1196 167, 17, 350, 351, 27, 168, 195, 196, 333, 327,
1197 474, 204, 437, 319, -191, 264, 137, 363, 364, 7,
1198 141, 302, 475, 306, 11, 3, 306, 310, 230, 84,
1199 492, 87, 74, 329, 184, 264, 496, 465, 372, 42,
1200 43, 248, 290, 152, 205, 295, 296, -191, 231, 299,
1201 4, 301, 11, 343, 373, 353, 308, 466, 16, 4,
1202 363, 364, 377, 490, 7, 343, 200, 389, 494, 344,
1203 16, 203, 232, 7, 363, 364, 461, 389, 378, 16,
1204 84, 87, 81, 390, 357, 358, 359, 360, 361, 420,
1205 339, 4, -40, 393, 5, 75, 76, 11, 274, 6,
1206 275, 276, 277, 401, 164, 7, 11, 80, -40, 163,
1207 191, 8, 343, 164, 9, 194, 354, 16, 489, 261,
1208 262, 493, 453, 265, 16, 453, 273, 370, 371, 495,
1209 174, 10, 233, 497, 188, 476, 190, 170, 11, 77,
1210 78, 186, 441, 265, 368, 369, 370, 371, 278, 236,
1211 236, 266, 41, 41, 25, 25, 39, 39, 250, 171,
1212 234, 234, 172, 237, 237, 443, 425, 426, 427, 428,
1213 429, 430, 431, 432, 433, 255, 415, 176, 12, 82,
1214 83, 173, 456, 178, 13, 14, 367, 368, 369, 370,
1215 371, 175, 306, 185, 78, 192, 78, 365, 451, 366,
1216 367, 368, 369, 370, 371, 279, 434, 193, 78, 15,
1217 483, 311, 312, 167, 16, 318, 280, 177, 168, 488,
1218 195, 196, 180, 47, 244, 245, 438, 450, 324, 181,
1219 328, 182, 281, 282, 183, 283, 274, 284, 275, 276,
1220 277, 289, 189, 285, 345, 41, 198, 25, 464, 39,
1221 199, 346, 328, 345, 458, 201, 306, 202, 54, 206,
1222 346, 261, 359, 251, 252, 313, 314, 207, 478, 55,
1223 56, 362, 323, 16, 208, 44, 57, 484, 407, 16,
1224 363, 364, 486, 363, 364, 274, 278, 275, 276, 277,
1225 294, 45, 209, 46, 210, 211, 212, 213, 214, 47,
1226 215, 59, 216, 48, 217, 218, 62, 274, 219, 275,
1227 276, 277, 220, 221, 405, 222, 49, 223, 403, 224,
1228 50, 51, 412, 225, 41, 52, 25, 53, 39, 226,
1229 227, 405, 228, 229, 54, 278, 416, 243, 246, 253,
1230 256, 448, 422, 279, -191, 55, 56, 257, 271, 291,
1231 292, 297, 57, 298, 280, 300, 303, 278, 316, 320,
1232 321, 322, 326, 331, 340, 332, 388, 338, 363, 364,
1233 281, 282, 341, 283, 342, 284, 58, 59, 60, 61,
1234 352, 285, 62, 355, 356, 392, 374, 63, 402, 375,
1235 376, 379, 279, 380, 64, 381, 65, 382, 383, 384,
1236 385, 467, 67, 280, 386, 391, 365, 395, 366, 367,
1237 368, 369, 370, 371, 279, 44, 396, 397, 398, 281,
1238 282, 387, 283, 16, 284, 280, 399, 400, 404, 10,
1239 285, 45, 406, 46, 41, 409, 25, 413, 39, 47,
1240 419, 281, 282, 48, 283, 417, 284, 435, 418, 439,
1241 472, 274, 285, 275, 276, 277, 49, 421, 482, 424,
1242 50, 51, 436, 440, 442, 52, 345, 53, 444, 472,
1243 446, 449, 345, 346, 54, 363, 364, 472, 452, 346,
1244 453, 472, 457, 462, 481, 55, 56, 480, 479, 485,
1245 162, 365, 57, 366, 367, 368, 369, 370, 371, 498,
1246 410, 278, 414, 487, 274, 44, 275, 276, 277, 309,
1247 499, 272, 29, 408, 35, 38, 58, 59, 60, 61,
1248 307, 45, 62, 46, 0, 363, 364, 63, 349, 47,
1249 0, 0, 0, 48, 64, 0, 65, 0, 0, 0,
1250 0, 66, 67, 363, 364, 0, 49, 0, 0, 0,
1251 50, 51, 0, 0, 278, 52, 0, 53, 279, 0,
1252 0, 0, 0, 16, 54, 0, 0, 0, 0, 280,
1253 0, 0, 0, 0, 0, 55, 56, 0, 0, 0,
1254 0, 0, 57, 0, 0, 281, 282, 0, 459, 0,
1255 284, 0, 0, 0, 0, 0, 285, 0, 365, 0,
1256 366, 367, 368, 369, 370, 371, 58, 59, 60, 61,
1257 0, 279, 62, 394, 0, 0, 0, 63, 0, 0,
1258 0, 0, 280, 0, 64, 0, 65, 0, 0, 0,
1259 0, 66, 67, 0, 0, 0, 0, 0, 281, 282,
1260 0, 283, 0, 284, 0, 0, 0, 0, 365, 285,
1261 366, 367, 368, 369, 370, 371, 0, 0, 44, 0,
1262 0, 0, 0, 423, 0, 0, 365, 491, 366, 367,
1263 368, 369, 370, 371, 45, 0, 46, 0, 0, 0,
1264 0, 0, 47, 0, 0, 5, 48, 0, 0, 0,
1265 6, 0, 0, 4, 0, 0, 5, 0, 0, 49,
1266 0, 6, 8, 50, 51, 9, 0, 7, 52, 0,
1267 53, 0, 0, 8, 0, 0, 9, 54, 0, 5,
1268 0, 0, 10, 0, 6, 0, 0, 0, 55, 56,
1269 0, 0, 0, 10, 233, 57, 8, 0, 0, 9,
1270 11, 0, 0, 4, 0, 0, 5, 0, 0, 0,
1271 0, 6, 0, 0, 0, 0, 10, 7, 0, 58,
1272 59, 60, 61, 8, 0, 62, 9, 0, 0, 12,
1273 63, 0, 0, 0, 0, 13, 14, 64, 0, 65,
1274 12, 0, 0, 10, 66, 67, 13, 14, 0, 0,
1275 11, 0, 0, 0, 0, 0, 0, 0, 0, 0,
1276 15, 0, 0, 12, 334, 16, 0, 5, 0, 13,
1277 14, 15, 6, 0, 0, 242, 16, 0, 0, 0,
1278 0, 0, 0, 0, 8, 0, 0, 9, 0, 0,
1279 12, 0, 0, 0, 15, 0, 13, 14, 411, 16,
1280 0, 0, 0, 0, 10, 0, 0, 0, 0, 0,
1281 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
1282 0, 15, 0, 0, 0, 0, 16, 0, 0, 0,
1283 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
1284 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
1285 88, 12, 89, 90, 0, 91, 92, 13, 14, 0,
1286 0, 93, 0, 94, 0, 0, 0, 0, 0, 0,
1287 95, 96, 97, 98, 0, 99, 100, 101, 102, 103,
1288 0, 104, 15, 105, 106, 107, 455, 16, 108, 0,
1289 0, 0, 109, 0, 110, 111, 112, 113, 114, 115,
1290 0, 116, 117, 118, 119, 120, 0, 0, 121, 0,
1291 122, 0, 0, 0, 0, 123, 0, 124, 0, 0,
1292 0, 125, 126, 127, 128, 129, 130, 131, 132, 133,
1293 0, 134, 135, 136, 137, 138, 139, 140, 141, 142,
1294 143, 144, 0, 0, 0, 0, 145, 0, 0, 146,
1295 0, 147, 148, 0, 0, 149, 150, 151, 0, 0,
1296 0, 152, 0, 153, 154, 155, 156, 0, 0, 157
1297 };
1298
1299 static const short int yycheck[] =
1300 {
1301 2, 5, 72, 2, 13, 2, 2, 2, 11, 12,
1302 23, 2, 265, 266, 2, 23, 3, 4, 253, 82,
1303 26, 117, 389, 230, 117, 32, 97, 11, 12, 43,
1304 101, 218, 38, 220, 76, 0, 223, 224, 133, 12,
1305 485, 14, 148, 249, 48, 32, 491, 133, 133, 3,
1306 4, 93, 208, 124, 150, 211, 212, 150, 153, 215,
1307 29, 217, 76, 147, 149, 271, 222, 153, 152, 29,
1308 11, 12, 133, 483, 43, 147, 80, 133, 488, 151,
1309 152, 85, 10, 43, 11, 12, 453, 133, 149, 152,
1310 63, 64, 8, 149, 281, 282, 283, 284, 285, 352,
1311 256, 29, 133, 149, 32, 3, 4, 76, 3, 37,
1312 5, 6, 7, 320, 83, 43, 76, 32, 149, 79,
1313 60, 49, 147, 83, 52, 65, 151, 152, 148, 199,
1314 200, 148, 152, 140, 152, 152, 206, 140, 141, 489,
1315 150, 69, 70, 493, 57, 151, 59, 147, 76, 3,
1316 4, 74, 405, 140, 138, 139, 140, 141, 53, 161,
1317 162, 148, 161, 162, 161, 162, 161, 162, 176, 147,
1318 161, 162, 147, 161, 162, 410, 363, 364, 365, 366,
1319 367, 368, 369, 370, 371, 189, 342, 150, 116, 3,
1320 4, 147, 445, 135, 122, 123, 137, 138, 139, 140,
1321 141, 147, 389, 3, 4, 3, 4, 134, 135, 136,
1322 137, 138, 139, 140, 141, 110, 372, 3, 4, 147,
1323 473, 225, 226, 236, 152, 229, 121, 147, 236, 482,
1324 3, 4, 150, 28, 3, 4, 392, 424, 247, 147,
1325 249, 147, 137, 138, 147, 140, 3, 142, 5, 6,
1326 7, 8, 148, 148, 263, 254, 8, 254, 153, 254,
1327 150, 263, 271, 272, 451, 147, 453, 150, 63, 148,
1328 272, 341, 459, 3, 4, 8, 9, 148, 465, 74,
1329 75, 285, 151, 152, 148, 4, 81, 474, 151, 152,
1330 11, 12, 479, 11, 12, 3, 53, 5, 6, 7,
1331 8, 20, 148, 22, 148, 148, 148, 148, 148, 28,
1332 148, 106, 148, 32, 148, 148, 111, 3, 148, 5,
1333 6, 7, 148, 148, 328, 148, 45, 148, 324, 148,
1334 49, 50, 336, 148, 333, 54, 333, 56, 333, 148,
1335 148, 345, 148, 148, 63, 53, 345, 3, 150, 150,
1336 154, 421, 356, 110, 150, 74, 75, 149, 148, 8,
1337 8, 8, 81, 8, 121, 8, 56, 53, 5, 152,
1338 148, 147, 135, 147, 151, 150, 3, 149, 11, 12,
1339 137, 138, 133, 140, 154, 142, 105, 106, 107, 108,
1340 133, 148, 111, 149, 148, 133, 149, 116, 8, 149,
1341 149, 149, 110, 149, 123, 149, 125, 149, 149, 149,
1342 149, 130, 131, 121, 149, 149, 134, 149, 136, 137,
1343 138, 139, 140, 141, 110, 4, 149, 149, 155, 137,
1344 138, 149, 140, 152, 142, 121, 149, 149, 135, 69,
1345 148, 20, 147, 22, 443, 151, 443, 147, 443, 28,
1346 149, 137, 138, 32, 140, 147, 142, 8, 147, 5,
1347 462, 3, 148, 5, 6, 7, 45, 149, 472, 149,
1348 49, 50, 149, 149, 147, 54, 485, 56, 113, 481,
1349 147, 149, 491, 485, 63, 11, 12, 489, 149, 491,
1350 152, 493, 150, 148, 133, 74, 75, 149, 152, 135,
1351 21, 134, 81, 136, 137, 138, 139, 140, 141, 149,
1352 332, 53, 341, 481, 3, 4, 5, 6, 7, 223,
1353 149, 205, 2, 330, 2, 2, 105, 106, 107, 108,
1354 221, 20, 111, 22, -1, 11, 12, 116, 264, 28,
1355 -1, -1, -1, 32, 123, -1, 125, -1, -1, -1,
1356 -1, 130, 131, 11, 12, -1, 45, -1, -1, -1,
1357 49, 50, -1, -1, 53, 54, -1, 56, 110, -1,
1358 -1, -1, -1, 152, 63, -1, -1, -1, -1, 121,
1359 -1, -1, -1, -1, -1, 74, 75, -1, -1, -1,
1360 -1, -1, 81, -1, -1, 137, 138, -1, 140, -1,
1361 142, -1, -1, -1, -1, -1, 148, -1, 134, -1,
1362 136, 137, 138, 139, 140, 141, 105, 106, 107, 108,
1363 -1, 110, 111, 149, -1, -1, -1, 116, -1, -1,
1364 -1, -1, 121, -1, 123, -1, 125, -1, -1, -1,
1365 -1, 130, 131, -1, -1, -1, -1, -1, 137, 138,
1366 -1, 140, -1, 142, -1, -1, -1, -1, 134, 148,
1367 136, 137, 138, 139, 140, 141, -1, -1, 4, -1,
1368 -1, -1, -1, 149, -1, -1, 134, 135, 136, 137,
1369 138, 139, 140, 141, 20, -1, 22, -1, -1, -1,
1370 -1, -1, 28, -1, -1, 32, 32, -1, -1, -1,
1371 37, -1, -1, 29, -1, -1, 32, -1, -1, 45,
1372 -1, 37, 49, 49, 50, 52, -1, 43, 54, -1,
1373 56, -1, -1, 49, -1, -1, 52, 63, -1, 32,
1374 -1, -1, 69, -1, 37, -1, -1, -1, 74, 75,
1375 -1, -1, -1, 69, 70, 81, 49, -1, -1, 52,
1376 76, -1, -1, 29, -1, -1, 32, -1, -1, -1,
1377 -1, 37, -1, -1, -1, -1, 69, 43, -1, 105,
1378 106, 107, 108, 49, -1, 111, 52, -1, -1, 116,
1379 116, -1, -1, -1, -1, 122, 123, 123, -1, 125,
1380 116, -1, -1, 69, 130, 131, 122, 123, -1, -1,
1381 76, -1, -1, -1, -1, -1, -1, -1, -1, -1,
1382 147, -1, -1, 116, 151, 152, -1, 32, -1, 122,
1383 123, 147, 37, -1, -1, 151, 152, -1, -1, -1,
1384 -1, -1, -1, -1, 49, -1, -1, 52, -1, -1,
1385 116, -1, -1, -1, 147, -1, 122, 123, 151, 152,
1386 -1, -1, -1, -1, 69, -1, -1, -1, -1, -1,
1387 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
1388 -1, 147, -1, -1, -1, -1, 152, -1, -1, -1,
1389 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
1390 -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
1391 13, 116, 15, 16, -1, 18, 19, 122, 123, -1,
1392 -1, 24, -1, 26, -1, -1, -1, -1, -1, -1,
1393 33, 34, 35, 36, -1, 38, 39, 40, 41, 42,
1394 -1, 44, 147, 46, 47, 48, 151, 152, 51, -1,
1395 -1, -1, 55, -1, 57, 58, 59, 60, 61, 62,
1396 -1, 64, 65, 66, 67, 68, -1, -1, 71, -1,
1397 73, -1, -1, -1, -1, 78, -1, 80, -1, -1,
1398 -1, 84, 85, 86, 87, 88, 89, 90, 91, 92,
1399 -1, 94, 95, 96, 97, 98, 99, 100, 101, 102,
1400 103, 104, -1, -1, -1, -1, 109, -1, -1, 112,
1401 -1, 114, 115, -1, -1, 118, 119, 120, -1, -1,
1402 -1, 124, -1, 126, 127, 128, 129, -1, -1, 132
1403 };
1404
1405 /* YYSTOS[STATE-NUM] -- The (internal number of the) accessing
1406 symbol of state STATE-NUM. */
1407 static const unsigned char yystos[] =
1408 {
1409 0, 157, 158, 0, 29, 32, 37, 43, 49, 52,
1410 69, 76, 116, 122, 123, 147, 152, 161, 162, 163,
1411 164, 167, 168, 176, 184, 188, 194, 205, 206, 207,
1412 210, 211, 214, 216, 217, 218, 219, 221, 222, 227,
1413 229, 230, 3, 4, 4, 20, 22, 28, 32, 45,
1414 49, 50, 54, 56, 63, 74, 75, 81, 105, 106,
1415 107, 108, 111, 116, 123, 125, 130, 131, 188, 202,
1416 204, 227, 228, 230, 148, 3, 4, 3, 4, 200,
1417 32, 8, 3, 4, 200, 175, 176, 200, 13, 15,
1418 16, 18, 19, 24, 26, 33, 34, 35, 36, 38,
1419 39, 40, 41, 42, 44, 46, 47, 48, 51, 55,
1420 57, 58, 59, 60, 61, 62, 64, 65, 66, 67,
1421 68, 71, 73, 78, 80, 84, 85, 86, 87, 88,
1422 89, 90, 91, 92, 94, 95, 96, 97, 98, 99,
1423 100, 101, 102, 103, 104, 109, 112, 114, 115, 118,
1424 119, 120, 124, 126, 127, 128, 129, 132, 177, 179,
1425 226, 159, 159, 79, 83, 166, 205, 210, 216, 220,
1426 147, 147, 147, 147, 150, 147, 150, 147, 135, 215,
1427 150, 147, 147, 147, 228, 3, 74, 203, 203, 148,
1428 203, 204, 3, 3, 204, 3, 4, 201, 8, 150,
1429 228, 147, 150, 228, 117, 150, 148, 148, 148, 148,
1430 148, 148, 148, 148, 148, 148, 148, 148, 148, 148,
1431 148, 148, 148, 148, 148, 148, 148, 148, 148, 148,
1432 133, 153, 10, 70, 161, 165, 176, 205, 207, 218,
1433 219, 222, 151, 3, 3, 4, 150, 208, 93, 212,
1434 216, 3, 4, 150, 160, 228, 154, 149, 185, 186,
1435 187, 201, 201, 195, 32, 140, 148, 201, 223, 224,
1436 225, 148, 195, 201, 3, 5, 6, 7, 53, 110,
1437 121, 137, 138, 140, 142, 148, 191, 192, 193, 8,
1438 193, 8, 8, 178, 8, 193, 193, 8, 8, 193,
1439 8, 193, 191, 56, 189, 190, 191, 226, 193, 189,
1440 191, 228, 228, 8, 9, 180, 5, 231, 228, 179,
1441 152, 148, 147, 151, 175, 209, 135, 82, 175, 197,
1442 213, 147, 150, 160, 151, 161, 175, 198, 149, 193,
1443 151, 133, 154, 147, 151, 175, 176, 196, 197, 223,
1444 224, 224, 133, 197, 151, 149, 148, 191, 191, 191,
1445 191, 191, 228, 11, 12, 134, 136, 137, 138, 139,
1446 140, 141, 133, 149, 149, 149, 149, 133, 149, 149,
1447 149, 149, 149, 149, 149, 149, 149, 149, 3, 133,
1448 149, 149, 133, 149, 149, 149, 149, 149, 155, 149,
1449 149, 179, 8, 219, 135, 228, 147, 151, 198, 151,
1450 164, 151, 228, 147, 187, 193, 230, 147, 147, 149,
1451 224, 149, 228, 149, 149, 191, 191, 191, 191, 191,
1452 191, 191, 191, 191, 193, 8, 149, 190, 193, 5,
1453 149, 224, 147, 160, 113, 181, 147, 199, 201, 149,
1454 191, 135, 149, 152, 173, 151, 224, 150, 191, 140,
1455 174, 190, 148, 182, 153, 133, 153, 130, 169, 170,
1456 171, 172, 176, 228, 26, 38, 151, 183, 191, 152,
1457 149, 133, 228, 224, 191, 135, 191, 172, 224, 148,
1458 173, 135, 196, 148, 173, 169, 196, 169, 149, 149
1459 };
1460
1461 #define yyerrok (yyerrstatus = 0)
1462 #define yyclearin (yychar = YYEMPTY)
1463 #define YYEMPTY (-2)
1464 #define YYEOF 0
1465
1466 #define YYACCEPT goto yyacceptlab
1467 #define YYABORT goto yyabortlab
1468 #define YYERROR goto yyerrorlab
1469
1470
1471 /* Like YYERROR except do call yyerror. This remains here temporarily
1472 to ease the transition to the new meaning of YYERROR, for GCC.
1473 Once GCC version 2 has supplanted version 1, this can go. */
1474
1475 #define YYFAIL goto yyerrlab
1476
1477 #define YYRECOVERING() (!!yyerrstatus)
1478
1479 #define YYBACKUP(Token, Value) \
1480 do \
1481 if (yychar == YYEMPTY && yylen == 1) \
1482 { \
1483 yychar = (Token); \
1484 yylval = (Value); \
1485 yytoken = YYTRANSLATE (yychar); \
1486 YYPOPSTACK; \
1487 goto yybackup; \
1488 } \
1489 else \
1490 { \
1491 yyerror (YY_("syntax error: cannot back up")); \
1492 YYERROR; \
1493 } \
1494 while (0)
1495
1496
1497 #define YYTERROR 1
1498 #define YYERRCODE 256
1499
1500
1501 /* YYLLOC_DEFAULT -- Set CURRENT to span from RHS[1] to RHS[N].
1502 If N is 0, then set CURRENT to the empty location which ends
1503 the previous symbol: RHS[0] (always defined). */
1504
1505 #define YYRHSLOC(Rhs, K) ((Rhs)[K])
1506 #ifndef YYLLOC_DEFAULT
1507 # define YYLLOC_DEFAULT(Current, Rhs, N) \
1508 do \
1509 if (N) \
1510 { \
1511 (Current).first_line = YYRHSLOC (Rhs, 1).first_line; \
1512 (Current).first_column = YYRHSLOC (Rhs, 1).first_column; \
1513 (Current).last_line = YYRHSLOC (Rhs, N).last_line; \
1514 (Current).last_column = YYRHSLOC (Rhs, N).last_column; \
1515 } \
1516 else \
1517 { \
1518 (Current).first_line = (Current).last_line = \
1519 YYRHSLOC (Rhs, 0).last_line; \
1520 (Current).first_column = (Current).last_column = \
1521 YYRHSLOC (Rhs, 0).last_column; \
1522 } \
1523 while (0)
1524 #endif
1525
1526
1527 /* YY_LOCATION_PRINT -- Print the location on the stream.
1528 This macro was not mandated originally: define only if we know
1529 we won't break user code: when these are the locations we know. */
1530
1531 #ifndef YY_LOCATION_PRINT
1532 # if YYLTYPE_IS_TRIVIAL
1533 # define YY_LOCATION_PRINT(File, Loc) \
1534 fprintf (File, "%d.%d-%d.%d", \
1535 (Loc).first_line, (Loc).first_column, \
1536 (Loc).last_line, (Loc).last_column)
1537 # else
1538 # define YY_LOCATION_PRINT(File, Loc) ((void) 0)
1539 # endif
1540 #endif
1541
1542
1543 /* YYLEX -- calling `yylex' with the right arguments. */
1544
1545 #ifdef YYLEX_PARAM
1546 # define YYLEX yylex (YYLEX_PARAM)
1547 #else
1548 # define YYLEX yylex ()
1549 #endif
1550
1551 /* Enable debugging if requested. */
1552 #if YYDEBUG
1553
1554 # ifndef YYFPRINTF
1555 # include <stdio.h> /* INFRINGES ON USER NAME SPACE */
1556 # define YYFPRINTF fprintf
1557 # endif
1558
1559 # define YYDPRINTF(Args) \
1560 do { \
1561 if (yydebug) \
1562 YYFPRINTF Args; \
1563 } while (0)
1564
1565 # define YY_SYMBOL_PRINT(Title, Type, Value, Location) \
1566 do { \
1567 if (yydebug) \
1568 { \
1569 YYFPRINTF (stderr, "%s ", Title); \
1570 yysymprint (stderr, \
1571 Type, Value); \
1572 YYFPRINTF (stderr, "\n"); \
1573 } \
1574 } while (0)
1575
1576 /*------------------------------------------------------------------.
1577 | yy_stack_print -- Print the state stack from its BOTTOM up to its |
1578 | TOP (included). |
1579 `------------------------------------------------------------------*/
1580
1581 #if defined (__STDC__) || defined (__cplusplus)
1582 static void
1583 yy_stack_print (short int *bottom, short int *top)
1584 #else
1585 static void
1586 yy_stack_print (bottom, top)
1587 short int *bottom;
1588 short int *top;
1589 #endif
1590 {
1591 YYFPRINTF (stderr, "Stack now");
1592 for (/* Nothing. */; bottom <= top; ++bottom)
1593 YYFPRINTF (stderr, " %d", *bottom);
1594 YYFPRINTF (stderr, "\n");
1595 }
1596
1597 # define YY_STACK_PRINT(Bottom, Top) \
1598 do { \
1599 if (yydebug) \
1600 yy_stack_print ((Bottom), (Top)); \
1601 } while (0)
1602
1603
1604 /*------------------------------------------------.
1605 | Report that the YYRULE is going to be reduced. |
1606 `------------------------------------------------*/
1607
1608 #if defined (__STDC__) || defined (__cplusplus)
1609 static void
1610 yy_reduce_print (int yyrule)
1611 #else
1612 static void
1613 yy_reduce_print (yyrule)
1614 int yyrule;
1615 #endif
1616 {
1617 int yyi;
1618 unsigned long int yylno = yyrline[yyrule];
1619 YYFPRINTF (stderr, "Reducing stack by rule %d (line %lu), ",
1620 yyrule - 1, yylno);
1621 /* Print the symbols being reduced, and their result. */
1622 for (yyi = yyprhs[yyrule]; 0 <= yyrhs[yyi]; yyi++)
1623 YYFPRINTF (stderr, "%s ", yytname[yyrhs[yyi]]);
1624 YYFPRINTF (stderr, "-> %s\n", yytname[yyr1[yyrule]]);
1625 }
1626
1627 # define YY_REDUCE_PRINT(Rule) \
1628 do { \
1629 if (yydebug) \
1630 yy_reduce_print (Rule); \
1631 } while (0)
1632
1633 /* Nonzero means print parse trace. It is left uninitialized so that
1634 multiple parsers can coexist. */
1635 int yydebug;
1636 #else /* !YYDEBUG */
1637 # define YYDPRINTF(Args)
1638 # define YY_SYMBOL_PRINT(Title, Type, Value, Location)
1639 # define YY_STACK_PRINT(Bottom, Top)
1640 # define YY_REDUCE_PRINT(Rule)
1641 #endif /* !YYDEBUG */
1642
1643
1644 /* YYINITDEPTH -- initial size of the parser's stacks. */
1645 #ifndef YYINITDEPTH
1646 # define YYINITDEPTH 200
1647 #endif
1648
1649 /* YYMAXDEPTH -- maximum size the stacks can grow to (effective only
1650 if the built-in stack extension method is used).
1651
1652 Do not make this value too large; the results are undefined if
1653 YYSTACK_ALLOC_MAXIMUM < YYSTACK_BYTES (YYMAXDEPTH)
1654 evaluated with infinite-precision integer arithmetic. */
1655
1656 #ifndef YYMAXDEPTH
1657 # define YYMAXDEPTH 10000
1658 #endif
1659
1660 \f
1661
1662 #if YYERROR_VERBOSE
1663
1664 # ifndef yystrlen
1665 # if defined (__GLIBC__) && defined (_STRING_H)
1666 # define yystrlen strlen
1667 # else
1668 /* Return the length of YYSTR. */
1669 static YYSIZE_T
1670 # if defined (__STDC__) || defined (__cplusplus)
1671 yystrlen (const char *yystr)
1672 # else
1673 yystrlen (yystr)
1674 const char *yystr;
1675 # endif
1676 {
1677 const char *yys = yystr;
1678
1679 while (*yys++ != '\0')
1680 continue;
1681
1682 return yys - yystr - 1;
1683 }
1684 # endif
1685 # endif
1686
1687 # ifndef yystpcpy
1688 # if defined (__GLIBC__) && defined (_STRING_H) && defined (_GNU_SOURCE)
1689 # define yystpcpy stpcpy
1690 # else
1691 /* Copy YYSRC to YYDEST, returning the address of the terminating '\0' in
1692 YYDEST. */
1693 static char *
1694 # if defined (__STDC__) || defined (__cplusplus)
1695 yystpcpy (char *yydest, const char *yysrc)
1696 # else
1697 yystpcpy (yydest, yysrc)
1698 char *yydest;
1699 const char *yysrc;
1700 # endif
1701 {
1702 char *yyd = yydest;
1703 const char *yys = yysrc;
1704
1705 while ((*yyd++ = *yys++) != '\0')
1706 continue;
1707
1708 return yyd - 1;
1709 }
1710 # endif
1711 # endif
1712
1713 # ifndef yytnamerr
1714 /* Copy to YYRES the contents of YYSTR after stripping away unnecessary
1715 quotes and backslashes, so that it's suitable for yyerror. The
1716 heuristic is that double-quoting is unnecessary unless the string
1717 contains an apostrophe, a comma, or backslash (other than
1718 backslash-backslash). YYSTR is taken from yytname. If YYRES is
1719 null, do not copy; instead, return the length of what the result
1720 would have been. */
1721 static YYSIZE_T
1722 yytnamerr (char *yyres, const char *yystr)
1723 {
1724 if (*yystr == '"')
1725 {
1726 size_t yyn = 0;
1727 char const *yyp = yystr;
1728
1729 for (;;)
1730 switch (*++yyp)
1731 {
1732 case '\'':
1733 case ',':
1734 goto do_not_strip_quotes;
1735
1736 case '\\':
1737 if (*++yyp != '\\')
1738 goto do_not_strip_quotes;
1739 /* Fall through. */
1740 default:
1741 if (yyres)
1742 yyres[yyn] = *yyp;
1743 yyn++;
1744 break;
1745
1746 case '"':
1747 if (yyres)
1748 yyres[yyn] = '\0';
1749 return yyn;
1750 }
1751 do_not_strip_quotes: ;
1752 }
1753
1754 if (! yyres)
1755 return yystrlen (yystr);
1756
1757 return yystpcpy (yyres, yystr) - yyres;
1758 }
1759 # endif
1760
1761 #endif /* YYERROR_VERBOSE */
1762
1763 \f
1764
1765 #if YYDEBUG
1766 /*--------------------------------.
1767 | Print this symbol on YYOUTPUT. |
1768 `--------------------------------*/
1769
1770 #if defined (__STDC__) || defined (__cplusplus)
1771 static void
1772 yysymprint (FILE *yyoutput, int yytype, YYSTYPE *yyvaluep)
1773 #else
1774 static void
1775 yysymprint (yyoutput, yytype, yyvaluep)
1776 FILE *yyoutput;
1777 int yytype;
1778 YYSTYPE *yyvaluep;
1779 #endif
1780 {
1781 /* Pacify ``unused variable'' warnings. */
1782 (void) yyvaluep;
1783
1784 if (yytype < YYNTOKENS)
1785 YYFPRINTF (yyoutput, "token %s (", yytname[yytype]);
1786 else
1787 YYFPRINTF (yyoutput, "nterm %s (", yytname[yytype]);
1788
1789
1790 # ifdef YYPRINT
1791 if (yytype < YYNTOKENS)
1792 YYPRINT (yyoutput, yytoknum[yytype], *yyvaluep);
1793 # endif
1794 switch (yytype)
1795 {
1796 default:
1797 break;
1798 }
1799 YYFPRINTF (yyoutput, ")");
1800 }
1801
1802 #endif /* ! YYDEBUG */
1803 /*-----------------------------------------------.
1804 | Release the memory associated to this symbol. |
1805 `-----------------------------------------------*/
1806
1807 #if defined (__STDC__) || defined (__cplusplus)
1808 static void
1809 yydestruct (const char *yymsg, int yytype, YYSTYPE *yyvaluep)
1810 #else
1811 static void
1812 yydestruct (yymsg, yytype, yyvaluep)
1813 const char *yymsg;
1814 int yytype;
1815 YYSTYPE *yyvaluep;
1816 #endif
1817 {
1818 /* Pacify ``unused variable'' warnings. */
1819 (void) yyvaluep;
1820
1821 if (!yymsg)
1822 yymsg = "Deleting";
1823 YY_SYMBOL_PRINT (yymsg, yytype, yyvaluep, yylocationp);
1824
1825 switch (yytype)
1826 {
1827
1828 default:
1829 break;
1830 }
1831 }
1832 \f
1833
1834 /* Prevent warnings from -Wmissing-prototypes. */
1835
1836 #ifdef YYPARSE_PARAM
1837 # if defined (__STDC__) || defined (__cplusplus)
1838 int yyparse (void *YYPARSE_PARAM);
1839 # else
1840 int yyparse ();
1841 # endif
1842 #else /* ! YYPARSE_PARAM */
1843 #if defined (__STDC__) || defined (__cplusplus)
1844 int yyparse (void);
1845 #else
1846 int yyparse ();
1847 #endif
1848 #endif /* ! YYPARSE_PARAM */
1849
1850
1851
1852 /* The look-ahead symbol. */
1853 int yychar;
1854
1855 /* The semantic value of the look-ahead symbol. */
1856 YYSTYPE yylval;
1857
1858 /* Number of syntax errors so far. */
1859 int yynerrs;
1860
1861
1862
1863 /*----------.
1864 | yyparse. |
1865 `----------*/
1866
1867 #ifdef YYPARSE_PARAM
1868 # if defined (__STDC__) || defined (__cplusplus)
1869 int yyparse (void *YYPARSE_PARAM)
1870 # else
1871 int yyparse (YYPARSE_PARAM)
1872 void *YYPARSE_PARAM;
1873 # endif
1874 #else /* ! YYPARSE_PARAM */
1875 #if defined (__STDC__) || defined (__cplusplus)
1876 int
1877 yyparse (void)
1878 #else
1879 int
1880 yyparse ()
1881 ;
1882 #endif
1883 #endif
1884 {
1885
1886 int yystate;
1887 int yyn;
1888 int yyresult;
1889 /* Number of tokens to shift before error messages enabled. */
1890 int yyerrstatus;
1891 /* Look-ahead token as an internal (translated) token number. */
1892 int yytoken = 0;
1893
1894 /* Three stacks and their tools:
1895 `yyss': related to states,
1896 `yyvs': related to semantic values,
1897 `yyls': related to locations.
1898
1899 Refer to the stacks thru separate pointers, to allow yyoverflow
1900 to reallocate them elsewhere. */
1901
1902 /* The state stack. */
1903 short int yyssa[YYINITDEPTH];
1904 short int *yyss = yyssa;
1905 short int *yyssp;
1906
1907 /* The semantic value stack. */
1908 YYSTYPE yyvsa[YYINITDEPTH];
1909 YYSTYPE *yyvs = yyvsa;
1910 YYSTYPE *yyvsp;
1911
1912
1913
1914 #define YYPOPSTACK (yyvsp--, yyssp--)
1915
1916 YYSIZE_T yystacksize = YYINITDEPTH;
1917
1918 /* The variables used to return semantic value and location from the
1919 action routines. */
1920 YYSTYPE yyval;
1921
1922
1923 /* When reducing, the number of symbols on the RHS of the reduced
1924 rule. */
1925 int yylen;
1926
1927 YYDPRINTF ((stderr, "Starting parse\n"));
1928
1929 yystate = 0;
1930 yyerrstatus = 0;
1931 yynerrs = 0;
1932 yychar = YYEMPTY; /* Cause a token to be read. */
1933
1934 /* Initialize stack pointers.
1935 Waste one element of value and location stack
1936 so that they stay on the same level as the state stack.
1937 The wasted elements are never initialized. */
1938
1939 yyssp = yyss;
1940 yyvsp = yyvs;
1941
1942 goto yysetstate;
1943
1944 /*------------------------------------------------------------.
1945 | yynewstate -- Push a new state, which is found in yystate. |
1946 `------------------------------------------------------------*/
1947 yynewstate:
1948 /* In all cases, when you get here, the value and location stacks
1949 have just been pushed. so pushing a state here evens the stacks.
1950 */
1951 yyssp++;
1952
1953 yysetstate:
1954 *yyssp = yystate;
1955
1956 if (yyss + yystacksize - 1 <= yyssp)
1957 {
1958 /* Get the current used size of the three stacks, in elements. */
1959 YYSIZE_T yysize = yyssp - yyss + 1;
1960
1961 #ifdef yyoverflow
1962 {
1963 /* Give user a chance to reallocate the stack. Use copies of
1964 these so that the &'s don't force the real ones into
1965 memory. */
1966 YYSTYPE *yyvs1 = yyvs;
1967 short int *yyss1 = yyss;
1968
1969
1970 /* Each stack pointer address is followed by the size of the
1971 data in use in that stack, in bytes. This used to be a
1972 conditional around just the two extra args, but that might
1973 be undefined if yyoverflow is a macro. */
1974 yyoverflow (YY_("memory exhausted"),
1975 &yyss1, yysize * sizeof (*yyssp),
1976 &yyvs1, yysize * sizeof (*yyvsp),
1977
1978 &yystacksize);
1979
1980 yyss = yyss1;
1981 yyvs = yyvs1;
1982 }
1983 #else /* no yyoverflow */
1984 # ifndef YYSTACK_RELOCATE
1985 goto yyexhaustedlab;
1986 # else
1987 /* Extend the stack our own way. */
1988 if (YYMAXDEPTH <= yystacksize)
1989 goto yyexhaustedlab;
1990 yystacksize *= 2;
1991 if (YYMAXDEPTH < yystacksize)
1992 yystacksize = YYMAXDEPTH;
1993
1994 {
1995 short int *yyss1 = yyss;
1996 union yyalloc *yyptr =
1997 (union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize));
1998 if (! yyptr)
1999 goto yyexhaustedlab;
2000 YYSTACK_RELOCATE (yyss);
2001 YYSTACK_RELOCATE (yyvs);
2002
2003 # undef YYSTACK_RELOCATE
2004 if (yyss1 != yyssa)
2005 YYSTACK_FREE (yyss1);
2006 }
2007 # endif
2008 #endif /* no yyoverflow */
2009
2010 yyssp = yyss + yysize - 1;
2011 yyvsp = yyvs + yysize - 1;
2012
2013
2014 YYDPRINTF ((stderr, "Stack size increased to %lu\n",
2015 (unsigned long int) yystacksize));
2016
2017 if (yyss + yystacksize - 1 <= yyssp)
2018 YYABORT;
2019 }
2020
2021 YYDPRINTF ((stderr, "Entering state %d\n", yystate));
2022
2023 goto yybackup;
2024
2025 /*-----------.
2026 | yybackup. |
2027 `-----------*/
2028 yybackup:
2029
2030 /* Do appropriate processing given the current state. */
2031 /* Read a look-ahead token if we need one and don't already have one. */
2032 /* yyresume: */
2033
2034 /* First try to decide what to do without reference to look-ahead token. */
2035
2036 yyn = yypact[yystate];
2037 if (yyn == YYPACT_NINF)
2038 goto yydefault;
2039
2040 /* Not known => get a look-ahead token if don't already have one. */
2041
2042 /* YYCHAR is either YYEMPTY or YYEOF or a valid look-ahead symbol. */
2043 if (yychar == YYEMPTY)
2044 {
2045 YYDPRINTF ((stderr, "Reading a token: "));
2046 yychar = YYLEX;
2047 }
2048
2049 if (yychar <= YYEOF)
2050 {
2051 yychar = yytoken = YYEOF;
2052 YYDPRINTF ((stderr, "Now at end of input.\n"));
2053 }
2054 else
2055 {
2056 yytoken = YYTRANSLATE (yychar);
2057 YY_SYMBOL_PRINT ("Next token is", yytoken, &yylval, &yylloc);
2058 }
2059
2060 /* If the proper action on seeing token YYTOKEN is to reduce or to
2061 detect an error, take that action. */
2062 yyn += yytoken;
2063 if (yyn < 0 || YYLAST < yyn || yycheck[yyn] != yytoken)
2064 goto yydefault;
2065 yyn = yytable[yyn];
2066 if (yyn <= 0)
2067 {
2068 if (yyn == 0 || yyn == YYTABLE_NINF)
2069 goto yyerrlab;
2070 yyn = -yyn;
2071 goto yyreduce;
2072 }
2073
2074 if (yyn == YYFINAL)
2075 YYACCEPT;
2076
2077 /* Shift the look-ahead token. */
2078 YY_SYMBOL_PRINT ("Shifting", yytoken, &yylval, &yylloc);
2079
2080 /* Discard the token being shifted unless it is eof. */
2081 if (yychar != YYEOF)
2082 yychar = YYEMPTY;
2083
2084 *++yyvsp = yylval;
2085
2086
2087 /* Count tokens shifted since error; after three, turn off error
2088 status. */
2089 if (yyerrstatus)
2090 yyerrstatus--;
2091
2092 yystate = yyn;
2093 goto yynewstate;
2094
2095
2096 /*-----------------------------------------------------------.
2097 | yydefault -- do the default action for the current state. |
2098 `-----------------------------------------------------------*/
2099 yydefault:
2100 yyn = yydefact[yystate];
2101 if (yyn == 0)
2102 goto yyerrlab;
2103 goto yyreduce;
2104
2105
2106 /*-----------------------------.
2107 | yyreduce -- Do a reduction. |
2108 `-----------------------------*/
2109 yyreduce:
2110 /* yyn is the number of a rule to reduce with. */
2111 yylen = yyr2[yyn];
2112
2113 /* If YYLEN is nonzero, implement the default value of the action:
2114 `$$ = $1'.
2115
2116 Otherwise, the following line sets YYVAL to garbage.
2117 This behavior is undocumented and Bison
2118 users should not rely upon it. Assigning to YYVAL
2119 unconditionally makes the parser a bit smaller, and it avoids a
2120 GCC warning that YYVAL may be used uninitialized. */
2121 yyval = yyvsp[1-yylen];
2122
2123
2124 YY_REDUCE_PRINT (yyn);
2125 switch (yyn)
2126 {
2127 case 2:
2128 #line 286 "parser.y"
2129 { fix_incomplete();
2130 check_all_user_types((yyvsp[0].ifref_list));
2131 write_proxies((yyvsp[0].ifref_list));
2132 write_client((yyvsp[0].ifref_list));
2133 write_server((yyvsp[0].ifref_list));
2134 write_dlldata((yyvsp[0].ifref_list));
2135 ;}
2136 break;
2137
2138 case 3:
2139 #line 295 "parser.y"
2140 { (yyval.ifref_list) = NULL; ;}
2141 break;
2142
2143 case 4:
2144 #line 296 "parser.y"
2145 { (yyval.ifref_list) = (yyvsp[-1].ifref_list); ;}
2146 break;
2147
2148 case 5:
2149 #line 297 "parser.y"
2150 { (yyval.ifref_list) = append_ifref( (yyvsp[-1].ifref_list), make_ifref((yyvsp[0].type)) ); ;}
2151 break;
2152
2153 case 6:
2154 #line 298 "parser.y"
2155 { (yyval.ifref_list) = (yyvsp[-2].ifref_list);
2156 reg_type((yyvsp[-1].type), (yyvsp[-1].type)->name, 0);
2157 if (!parse_only && do_header) write_coclass_forward((yyvsp[-1].type));
2158 ;}
2159 break;
2160
2161 case 7:
2162 #line 302 "parser.y"
2163 { (yyval.ifref_list) = (yyvsp[-1].ifref_list);
2164 add_typelib_entry((yyvsp[0].type));
2165 reg_type((yyvsp[0].type), (yyvsp[0].type)->name, 0);
2166 if (!parse_only && do_header) write_coclass_forward((yyvsp[0].type));
2167 ;}
2168 break;
2169
2170 case 8:
2171 #line 307 "parser.y"
2172 { (yyval.ifref_list) = (yyvsp[-1].ifref_list); add_typelib_entry((yyvsp[0].type)); ;}
2173 break;
2174
2175 case 9:
2176 #line 308 "parser.y"
2177 { (yyval.ifref_list) = (yyvsp[-1].ifref_list); ;}
2178 break;
2179
2180 case 10:
2181 #line 309 "parser.y"
2182 { (yyval.ifref_list) = (yyvsp[-1].ifref_list); ;}
2183 break;
2184
2185 case 11:
2186 #line 312 "parser.y"
2187 {;}
2188 break;
2189
2190 case 12:
2191 #line 313 "parser.y"
2192 { if (!parse_only) add_typelib_entry((yyvsp[0].type)); ;}
2193 break;
2194
2195 case 13:
2196 #line 314 "parser.y"
2197 { if (!parse_only) add_typelib_entry((yyvsp[0].type)); ;}
2198 break;
2199
2200 case 14:
2201 #line 315 "parser.y"
2202 { reg_type((yyvsp[-1].type), (yyvsp[-1].type)->name, 0); if (!parse_only && do_header) write_coclass_forward((yyvsp[-1].type)); ;}
2203 break;
2204
2205 case 15:
2206 #line 316 "parser.y"
2207 { if (!parse_only) add_typelib_entry((yyvsp[0].type));
2208 reg_type((yyvsp[0].type), (yyvsp[0].type)->name, 0);
2209 if (!parse_only && do_header) write_coclass_forward((yyvsp[0].type));
2210 ;}
2211 break;
2212
2213 case 16:
2214 #line 320 "parser.y"
2215 { if (!parse_only) add_typelib_entry((yyvsp[0].type)); ;}
2216 break;
2217
2218 case 17:
2219 #line 321 "parser.y"
2220 {;}
2221 break;
2222
2223 case 18:
2224 #line 322 "parser.y"
2225 {;}
2226 break;
2227
2228 case 19:
2229 #line 325 "parser.y"
2230 { (yyval.func_list) = NULL; ;}
2231 break;
2232
2233 case 20:
2234 #line 326 "parser.y"
2235 { (yyval.func_list) = append_func( (yyvsp[-2].func_list), (yyvsp[-1].func) ); ;}
2236 break;
2237
2238 case 21:
2239 #line 327 "parser.y"
2240 { (yyval.func_list) = (yyvsp[-1].func_list); ;}
2241 break;
2242
2243 case 22:
2244 #line 330 "parser.y"
2245 {;}
2246 break;
2247
2248 case 23:
2249 #line 331 "parser.y"
2250 { if (!parse_only && do_header) { write_constdef((yyvsp[-1].var)); } ;}
2251 break;
2252
2253 case 24:
2254 #line 332 "parser.y"
2255 {;}
2256 break;
2257
2258 case 25:
2259 #line 333 "parser.y"
2260 { if (!parse_only && do_header) {
2261 write_type_def_or_decl(header, (yyvsp[-1].type), FALSE, NULL);
2262 fprintf(header, ";\n\n");
2263 }
2264 ;}
2265 break;
2266
2267 case 26:
2268 #line 338 "parser.y"
2269 { if (!parse_only && do_header) { write_externdef((yyvsp[-1].var)); } ;}
2270 break;
2271
2272 case 27:
2273 #line 339 "parser.y"
2274 {;}
2275 break;
2276
2277 case 28:
2278 #line 340 "parser.y"
2279 { if (!parse_only && do_header) {
2280 write_type_def_or_decl(header, (yyvsp[-1].type), FALSE, NULL);
2281 fprintf(header, ";\n\n");
2282 }
2283 ;}
2284 break;
2285
2286 case 29:
2287 #line 345 "parser.y"
2288 {;}
2289 break;
2290
2291 case 30:
2292 #line 346 "parser.y"
2293 { if (!parse_only && do_header) {
2294 write_type_def_or_decl(header, (yyvsp[-1].type), FALSE, NULL);
2295 fprintf(header, ";\n\n");
2296 }
2297 ;}
2298 break;
2299
2300 case 31:
2301 #line 353 "parser.y"
2302 { if (!parse_only && do_header) fprintf(header, "%s\n", (yyvsp[-1].str)); ;}
2303 break;
2304
2305 case 32:
2306 #line 355 "parser.y"
2307 { assert(yychar == YYEMPTY);
2308 if (!do_import((yyvsp[-1].str))) yychar = aEOF; ;}
2309 break;
2310
2311 case 33:
2312 #line 358 "parser.y"
2313 {;}
2314 break;
2315
2316 case 34:
2317 #line 361 "parser.y"
2318 { if(!parse_only) add_importlib((yyvsp[-1].str)); ;}
2319 break;
2320
2321 case 35:
2322 #line 364 "parser.y"
2323 { (yyval.str) = (yyvsp[0].str); ;}
2324 break;
2325
2326 case 36:
2327 #line 366 "parser.y"
2328 { start_typelib((yyvsp[-1].str), (yyvsp[-2].attr_list));
2329 if (!parse_only && do_header) write_library((yyvsp[-1].str), (yyvsp[-2].attr_list));
2330 if (!parse_only && do_idfile) write_libid((yyvsp[-1].str), (yyvsp[-2].attr_list));
2331 ;}
2332 break;
2333
2334 case 37:
2335 #line 371 "parser.y"
2336 { end_typelib(); ;}
2337 break;
2338
2339 case 38:
2340 #line 374 "parser.y"
2341 { (yyval.var_list) = NULL; ;}
2342 break;
2343
2344 case 40:
2345 #line 378 "parser.y"
2346 { (yyval.var_list) = NULL; ;}
2347 break;
2348
2349 case 41:
2350 #line 381 "parser.y"
2351 { check_arg((yyvsp[0].var)); (yyval.var_list) = append_var( NULL, (yyvsp[0].var) ); ;}
2352 break;
2353
2354 case 42:
2355 #line 382 "parser.y"
2356 { check_arg((yyvsp[0].var)); (yyval.var_list) = append_var( (yyvsp[-2].var_list), (yyvsp[0].var)); ;}
2357 break;
2358
2359 case 44:
2360 #line 387 "parser.y"
2361 { (yyval.var) = (yyvsp[-1].pident)->var;
2362 (yyval.var)->attrs = (yyvsp[-3].attr_list);
2363 set_type((yyval.var), (yyvsp[-2].type), (yyvsp[-1].pident)->ptr_level, (yyvsp[0].array_dims), TRUE);
2364 free((yyvsp[-1].pident));
2365 ;}
2366 break;
2367
2368 case 45:
2369 #line 392 "parser.y"
2370 { (yyval.var) = (yyvsp[-1].pident)->var;
2371 set_type((yyval.var), (yyvsp[-2].type), (yyvsp[-1].pident)->ptr_level, (yyvsp[0].array_dims), TRUE);
2372 free((yyvsp[-1].pident));
2373 ;}
2374 break;
2375
2376 case 46:
2377 #line 396 "parser.y"
2378 { (yyval.var) = (yyvsp[-3].pident)->var;
2379 (yyval.var)->attrs = (yyvsp[-5].attr_list);
2380 set_type((yyval.var), (yyvsp[-4].type), (yyvsp[-3].pident)->ptr_level - 1, NULL, TRUE);
2381 free((yyvsp[-3].pident));
2382 (yyval.var)->args = (yyvsp[-1].var_list);
2383 ;}
2384 break;
2385
2386 case 47:
2387 #line 402 "parser.y"
2388 { (yyval.var) = (yyvsp[-3].pident)->var;
2389 set_type((yyval.var), (yyvsp[-4].type), (yyvsp[-3].pident)->ptr_level - 1, NULL, TRUE);
2390 free((yyvsp[-3].pident));
2391 (yyval.var)->args = (yyvsp[-1].var_list);
2392 ;}
2393 break;
2394
2395 case 48:
2396 #line 409 "parser.y"
2397 { (yyval.array_dims) = NULL; ;}
2398 break;
2399
2400 case 49:
2401 #line 410 "parser.y"
2402 { (yyval.array_dims) = (yyvsp[-1].array_dims); ;}
2403 break;
2404
2405 case 50:
2406 #line 411 "parser.y"
2407 { (yyval.array_dims) = append_array( NULL, make_expr(EXPR_VOID) ); ;}
2408 break;
2409
2410 case 51:
2411 #line 414 "parser.y"
2412 { (yyval.array_dims) = append_array( NULL, (yyvsp[0].expr) ); ;}
2413 break;
2414
2415 case 52:
2416 #line 415 "parser.y"
2417 { (yyval.array_dims) = append_array( (yyvsp[-2].array_dims), (yyvsp[0].expr) ); ;}
2418 break;
2419
2420 case 53:
2421 #line 416 "parser.y"
2422 { (yyval.array_dims) = append_array( (yyvsp[-3].array_dims), (yyvsp[0].expr) ); ;}
2423 break;
2424
2425 case 54:
2426 #line 419 "parser.y"
2427 { (yyval.attr_list) = NULL; ;}
2428 break;
2429
2430 case 56:
2431 #line 424 "parser.y"
2432 { (yyval.attr_list) = (yyvsp[-1].attr_list);
2433 if (!(yyval.attr_list))
2434 error_loc("empty attribute lists unsupported\n");
2435 ;}
2436 break;
2437
2438 case 57:
2439 #line 430 "parser.y"
2440 { (yyval.attr_list) = append_attr( NULL, (yyvsp[0].attr) ); ;}
2441 break;
2442
2443 case 58:
2444 #line 431 "parser.y"
2445 { (yyval.attr_list) = append_attr( (yyvsp[-2].attr_list), (yyvsp[0].attr) ); ;}
2446 break;
2447
2448 case 59:
2449 #line 432 "parser.y"
2450 { (yyval.attr_list) = append_attr( (yyvsp[-3].attr_list), (yyvsp[0].attr) ); ;}
2451 break;
2452
2453 case 60:
2454 #line 435 "parser.y"
2455 { (yyval.str_list) = append_str( NULL, (yyvsp[0].str) ); ;}
2456 break;
2457
2458 case 61:
2459 #line 436 "parser.y"
2460 { (yyval.str_list) = append_str( (yyvsp[-2].str_list), (yyvsp[0].str) ); ;}
2461 break;
2462
2463 case 62:
2464 #line 439 "parser.y"
2465 { (yyval.attr) = NULL; ;}
2466 break;
2467
2468 case 63:
2469 #line 440 "parser.y"
2470 { (yyval.attr) = make_attr(ATTR_AGGREGATABLE); ;}
2471 break;
2472
2473 case 64:
2474 #line 441 "parser.y"
2475 { (yyval.attr) = make_attr(ATTR_APPOBJECT); ;}
2476 break;
2477
2478 case 65:
2479 #line 442 "parser.y"
2480 { (yyval.attr) = make_attr(ATTR_ASYNC); ;}
2481 break;
2482
2483 case 66:
2484 #line 443 "parser.y"
2485 { (yyval.attr) = make_attr(ATTR_AUTO_HANDLE); ;}
2486 break;
2487
2488 case 67:
2489 #line 444 "parser.y"
2490 { (yyval.attr) = make_attr(ATTR_BINDABLE); ;}
2491 break;
2492
2493 case 68:
2494 #line 445 "parser.y"
2495 { (yyval.attr) = make_attrp(ATTR_CALLAS, (yyvsp[-1].var)); ;}
2496 break;
2497
2498 case 69:
2499 #line 446 "parser.y"
2500 { (yyval.attr) = make_attrp(ATTR_CASE, (yyvsp[-1].expr_list)); ;}
2501 break;
2502
2503 case 70:
2504 #line 447 "parser.y"
2505 { (yyval.attr) = make_attrv(ATTR_CONTEXTHANDLE, 0); ;}
2506 break;
2507
2508 case 71:
2509 #line 448 "parser.y"
2510 { (yyval.attr) = make_attrv(ATTR_CONTEXTHANDLE, 0); /* RPC_CONTEXT_HANDLE_DONT_SERIALIZE */ ;}
2511 break;
2512
2513 case 72:
2514 #line 449 "parser.y"
2515 { (yyval.attr) = make_attrv(ATTR_CONTEXTHANDLE, 0); /* RPC_CONTEXT_HANDLE_SERIALIZE */ ;}
2516 break;
2517
2518 case 73:
2519 #line 450 "parser.y"
2520 { (yyval.attr) = make_attr(ATTR_CONTROL); ;}
2521 break;
2522
2523 case 74:
2524 #line 451 "parser.y"
2525 { (yyval.attr) = make_attr(ATTR_DEFAULT); ;}
2526 break;
2527
2528 case 75:
2529 #line 452 "parser.y"
2530 { (yyval.attr) = make_attr(ATTR_DEFAULTCOLLELEM); ;}
2531 break;
2532
2533 case 76:
2534 #line 453 "parser.y"
2535 { (yyval.attr) = make_attrp(ATTR_DEFAULTVALUE_EXPR, (yyvsp[-1].expr)); ;}
2536 break;
2537
2538 case 77:
2539 #line 454 "parser.y"
2540 { (yyval.attr) = make_attrp(ATTR_DEFAULTVALUE_STRING, (yyvsp[-1].str)); ;}
2541 break;
2542
2543 case 78:
2544 #line 455 "parser.y"
2545 { (yyval.attr) = make_attr(ATTR_DEFAULTVTABLE); ;}
2546 break;
2547
2548 case 79:
2549 #line 456 "parser.y"
2550 { (yyval.attr) = make_attr(ATTR_DISPLAYBIND); ;}
2551 break;
2552
2553 case 80:
2554 #line 457 "parser.y"
2555 { (yyval.attr) = make_attrp(ATTR_DLLNAME, (yyvsp[-1].str)); ;}
2556 break;
2557
2558 case 81:
2559 #line 458 "parser.y"
2560 { (yyval.attr) = make_attr(ATTR_DUAL); ;}
2561 break;
2562
2563 case 82:
2564 #line 459 "parser.y"
2565 { (yyval.attr) = make_attrp(ATTR_ENDPOINT, (yyvsp[-1].str_list)); ;}
2566 break;
2567
2568 case 83:
2569 #line 460 "parser.y"
2570 { (yyval.attr) = make_attrp(ATTR_ENTRY_STRING, (yyvsp[-1].str)); ;}
2571 break;
2572
2573 case 84:
2574 #line 461 "parser.y"
2575 { (yyval.attr) = make_attrp(ATTR_ENTRY_ORDINAL, (yyvsp[-1].expr)); ;}
2576 break;
2577
2578 case 85:
2579 #line 462 "parser.y"
2580 { (yyval.attr) = make_attr(ATTR_EXPLICIT_HANDLE); ;}
2581 break;
2582
2583 case 86:
2584 #line 463 "parser.y"
2585 { (yyval.attr) = make_attr(ATTR_HANDLE); ;}
2586 break;
2587
2588 case 87:
2589 #line 464 "parser.y"
2590 { (yyval.attr) = make_attrp(ATTR_HELPCONTEXT, (yyvsp[-1].expr)); ;}
2591 break;
2592
2593 case 88:
2594 #line 465 "parser.y"
2595 { (yyval.attr) = make_attrp(ATTR_HELPFILE, (yyvsp[-1].str)); ;}
2596 break;
2597
2598 case 89:
2599 #line 466 "parser.y"
2600 { (yyval.attr) = make_attrp(ATTR_HELPSTRING, (yyvsp[-1].str)); ;}
2601 break;
2602
2603 case 90:
2604 #line 467 "parser.y"
2605 { (yyval.attr) = make_attrp(ATTR_HELPSTRINGCONTEXT, (yyvsp[-1].expr)); ;}
2606 break;
2607
2608 case 91:
2609 #line 468 "parser.y"
2610 { (yyval.attr) = make_attrp(ATTR_HELPSTRINGDLL, (yyvsp[-1].str)); ;}
2611 break;
2612
2613 case 92:
2614 #line 469 "parser.y"
2615 { (yyval.attr) = make_attr(ATTR_HIDDEN); ;}
2616 break;
2617
2618 case 93:
2619 #line 470 "parser.y"
2620 { (yyval.attr) = make_attrp(ATTR_ID, (yyvsp[-1].expr)); ;}
2621 break;
2622
2623 case 94:
2624 #line 471 "parser.y"
2625 { (yyval.attr) = make_attr(ATTR_IDEMPOTENT); ;}
2626 break;
2627
2628 case 95:
2629 #line 472 "parser.y"
2630 { (yyval.attr) = make_attrp(ATTR_IIDIS, (yyvsp[-1].expr)); ;}
2631 break;
2632
2633 case 96:
2634 #line 473 "parser.y"
2635 { (yyval.attr) = make_attr(ATTR_IMMEDIATEBIND); ;}
2636 break;
2637
2638