fixed optimzation for Atom
[platform/upstream/binutils.git] / binutils / rcparse.c
1 /* 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      BEG = 258,
70      END = 259,
71      ACCELERATORS = 260,
72      VIRTKEY = 261,
73      ASCII = 262,
74      NOINVERT = 263,
75      SHIFT = 264,
76      CONTROL = 265,
77      ALT = 266,
78      BITMAP = 267,
79      CURSOR = 268,
80      DIALOG = 269,
81      DIALOGEX = 270,
82      EXSTYLE = 271,
83      CAPTION = 272,
84      CLASS = 273,
85      STYLE = 274,
86      AUTO3STATE = 275,
87      AUTOCHECKBOX = 276,
88      AUTORADIOBUTTON = 277,
89      CHECKBOX = 278,
90      COMBOBOX = 279,
91      CTEXT = 280,
92      DEFPUSHBUTTON = 281,
93      EDITTEXT = 282,
94      GROUPBOX = 283,
95      LISTBOX = 284,
96      LTEXT = 285,
97      PUSHBOX = 286,
98      PUSHBUTTON = 287,
99      RADIOBUTTON = 288,
100      RTEXT = 289,
101      SCROLLBAR = 290,
102      STATE3 = 291,
103      USERBUTTON = 292,
104      BEDIT = 293,
105      HEDIT = 294,
106      IEDIT = 295,
107      FONT = 296,
108      ICON = 297,
109      ANICURSOR = 298,
110      ANIICON = 299,
111      DLGINCLUDE = 300,
112      DLGINIT = 301,
113      FONTDIR = 302,
114      HTML = 303,
115      MANIFEST = 304,
116      PLUGPLAY = 305,
117      VXD = 306,
118      TOOLBAR = 307,
119      BUTTON = 308,
120      LANGUAGE = 309,
121      CHARACTERISTICS = 310,
122      VERSIONK = 311,
123      MENU = 312,
124      MENUEX = 313,
125      MENUITEM = 314,
126      SEPARATOR = 315,
127      POPUP = 316,
128      CHECKED = 317,
129      GRAYED = 318,
130      HELP = 319,
131      INACTIVE = 320,
132      MENUBARBREAK = 321,
133      MENUBREAK = 322,
134      MESSAGETABLE = 323,
135      RCDATA = 324,
136      STRINGTABLE = 325,
137      VERSIONINFO = 326,
138      FILEVERSION = 327,
139      PRODUCTVERSION = 328,
140      FILEFLAGSMASK = 329,
141      FILEFLAGS = 330,
142      FILEOS = 331,
143      FILETYPE = 332,
144      FILESUBTYPE = 333,
145      BLOCKSTRINGFILEINFO = 334,
146      BLOCKVARFILEINFO = 335,
147      VALUE = 336,
148      BLOCK = 337,
149      MOVEABLE = 338,
150      FIXED = 339,
151      PURE = 340,
152      IMPURE = 341,
153      PRELOAD = 342,
154      LOADONCALL = 343,
155      DISCARDABLE = 344,
156      NOT = 345,
157      QUOTEDUNISTRING = 346,
158      QUOTEDSTRING = 347,
159      STRING = 348,
160      NUMBER = 349,
161      SIZEDUNISTRING = 350,
162      SIZEDSTRING = 351,
163      IGNORED_TOKEN = 352,
164      NEG = 353
165    };
166 #endif
167 /* Tokens.  */
168 #define BEG 258
169 #define END 259
170 #define ACCELERATORS 260
171 #define VIRTKEY 261
172 #define ASCII 262
173 #define NOINVERT 263
174 #define SHIFT 264
175 #define CONTROL 265
176 #define ALT 266
177 #define BITMAP 267
178 #define CURSOR 268
179 #define DIALOG 269
180 #define DIALOGEX 270
181 #define EXSTYLE 271
182 #define CAPTION 272
183 #define CLASS 273
184 #define STYLE 274
185 #define AUTO3STATE 275
186 #define AUTOCHECKBOX 276
187 #define AUTORADIOBUTTON 277
188 #define CHECKBOX 278
189 #define COMBOBOX 279
190 #define CTEXT 280
191 #define DEFPUSHBUTTON 281
192 #define EDITTEXT 282
193 #define GROUPBOX 283
194 #define LISTBOX 284
195 #define LTEXT 285
196 #define PUSHBOX 286
197 #define PUSHBUTTON 287
198 #define RADIOBUTTON 288
199 #define RTEXT 289
200 #define SCROLLBAR 290
201 #define STATE3 291
202 #define USERBUTTON 292
203 #define BEDIT 293
204 #define HEDIT 294
205 #define IEDIT 295
206 #define FONT 296
207 #define ICON 297
208 #define ANICURSOR 298
209 #define ANIICON 299
210 #define DLGINCLUDE 300
211 #define DLGINIT 301
212 #define FONTDIR 302
213 #define HTML 303
214 #define MANIFEST 304
215 #define PLUGPLAY 305
216 #define VXD 306
217 #define TOOLBAR 307
218 #define BUTTON 308
219 #define LANGUAGE 309
220 #define CHARACTERISTICS 310
221 #define VERSIONK 311
222 #define MENU 312
223 #define MENUEX 313
224 #define MENUITEM 314
225 #define SEPARATOR 315
226 #define POPUP 316
227 #define CHECKED 317
228 #define GRAYED 318
229 #define HELP 319
230 #define INACTIVE 320
231 #define MENUBARBREAK 321
232 #define MENUBREAK 322
233 #define MESSAGETABLE 323
234 #define RCDATA 324
235 #define STRINGTABLE 325
236 #define VERSIONINFO 326
237 #define FILEVERSION 327
238 #define PRODUCTVERSION 328
239 #define FILEFLAGSMASK 329
240 #define FILEFLAGS 330
241 #define FILEOS 331
242 #define FILETYPE 332
243 #define FILESUBTYPE 333
244 #define BLOCKSTRINGFILEINFO 334
245 #define BLOCKVARFILEINFO 335
246 #define VALUE 336
247 #define BLOCK 337
248 #define MOVEABLE 338
249 #define FIXED 339
250 #define PURE 340
251 #define IMPURE 341
252 #define PRELOAD 342
253 #define LOADONCALL 343
254 #define DISCARDABLE 344
255 #define NOT 345
256 #define QUOTEDUNISTRING 346
257 #define QUOTEDSTRING 347
258 #define STRING 348
259 #define NUMBER 349
260 #define SIZEDUNISTRING 350
261 #define SIZEDSTRING 351
262 #define IGNORED_TOKEN 352
263 #define NEG 353
264
265
266
267
268 /* Copy the first part of user declarations.  */
269 #line 1 "rcparse.y"
270  /* rcparse.y -- parser for Windows rc files
271    Copyright (C) 1997-2014 Free Software Foundation, Inc.
272    Written by Ian Lance Taylor, Cygnus Support.
273    Extended by Kai Tietz, Onevision.
274
275    This file is part of GNU Binutils.
276
277    This program is free software; you can redistribute it and/or modify
278    it under the terms of the GNU General Public License as published by
279    the Free Software Foundation; either version 3 of the License, or
280    (at your option) any later version.
281
282    This program is distributed in the hope that it will be useful,
283    but WITHOUT ANY WARRANTY; without even the implied warranty of
284    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
285    GNU General Public License for more details.
286
287    You should have received a copy of the GNU General Public License
288    along with this program; if not, write to the Free Software
289    Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA
290    02110-1301, USA.  */
291
292
293 /* This is a parser for Windows rc files.  It is based on the parser
294    by Gunther Ebert <gunther.ebert@ixos-leipzig.de>.  */
295
296 #include "sysdep.h"
297 #include "bfd.h"
298 #include "bucomm.h"
299 #include "libiberty.h"
300 #include "windres.h"
301 #include "safe-ctype.h"
302
303 /* The current language.  */
304
305 static unsigned short language;
306
307 /* The resource information during a sub statement.  */
308
309 static rc_res_res_info sub_res_info;
310
311 /* Dialog information.  This is built by the nonterminals styles and
312    controls.  */
313
314 static rc_dialog dialog;
315
316 /* This is used when building a style.  It is modified by the
317    nonterminal styleexpr.  */
318
319 static unsigned long style;
320
321 /* These are used when building a control.  They are set before using
322    control_params.  */
323
324 static rc_uint_type base_style;
325 static rc_uint_type default_style;
326 static rc_res_id class;
327 static rc_res_id res_text_field;
328 static unichar null_unichar;
329
330 /* This is used for COMBOBOX, LISTBOX and EDITTEXT which
331    do not allow resource 'text' field in control definition. */
332 static const rc_res_id res_null_text = { 1, {{0, &null_unichar}}};
333
334
335
336 /* Enabling traces.  */
337 #ifndef YYDEBUG
338 # define YYDEBUG 0
339 #endif
340
341 /* Enabling verbose error messages.  */
342 #ifdef YYERROR_VERBOSE
343 # undef YYERROR_VERBOSE
344 # define YYERROR_VERBOSE 1
345 #else
346 # define YYERROR_VERBOSE 0
347 #endif
348
349 /* Enabling the token table.  */
350 #ifndef YYTOKEN_TABLE
351 # define YYTOKEN_TABLE 0
352 #endif
353
354 #if ! defined YYSTYPE && ! defined YYSTYPE_IS_DECLARED
355 typedef union YYSTYPE
356 #line 68 "rcparse.y"
357 {
358   rc_accelerator acc;
359   rc_accelerator *pacc;
360   rc_dialog_control *dialog_control;
361   rc_menuitem *menuitem;
362   struct
363   {
364     rc_rcdata_item *first;
365     rc_rcdata_item *last;
366   } rcdata;
367   rc_rcdata_item *rcdata_item;
368   rc_fixed_versioninfo *fixver;
369   rc_ver_info *verinfo;
370   rc_ver_stringtable *verstringtable;
371   rc_ver_stringinfo *verstring;
372   rc_ver_varinfo *vervar;
373   rc_toolbar_item *toobar_item;
374   rc_res_id id;
375   rc_res_res_info res_info;
376   struct
377   {
378     rc_uint_type on;
379     rc_uint_type off;
380   } memflags;
381   struct
382   {
383     rc_uint_type val;
384     /* Nonzero if this number was explicitly specified as long.  */
385     int dword;
386   } i;
387   rc_uint_type il;
388   rc_uint_type is;
389   const char *s;
390   struct
391   {
392     rc_uint_type length;
393     const char *s;
394   } ss;
395   unichar *uni;
396   struct
397   {
398     rc_uint_type length;
399     const unichar *s;
400   } suni;
401 }
402 /* Line 193 of yacc.c.  */
403 #line 404 "rcparse.c"
404         YYSTYPE;
405 # define yystype YYSTYPE /* obsolescent; will be withdrawn */
406 # define YYSTYPE_IS_DECLARED 1
407 # define YYSTYPE_IS_TRIVIAL 1
408 #endif
409
410
411
412 /* Copy the second part of user declarations.  */
413
414
415 /* Line 216 of yacc.c.  */
416 #line 417 "rcparse.c"
417
418 #ifdef short
419 # undef short
420 #endif
421
422 #ifdef YYTYPE_UINT8
423 typedef YYTYPE_UINT8 yytype_uint8;
424 #else
425 typedef unsigned char yytype_uint8;
426 #endif
427
428 #ifdef YYTYPE_INT8
429 typedef YYTYPE_INT8 yytype_int8;
430 #elif (defined __STDC__ || defined __C99__FUNC__ \
431      || defined __cplusplus || defined _MSC_VER)
432 typedef signed char yytype_int8;
433 #else
434 typedef short int yytype_int8;
435 #endif
436
437 #ifdef YYTYPE_UINT16
438 typedef YYTYPE_UINT16 yytype_uint16;
439 #else
440 typedef unsigned short int yytype_uint16;
441 #endif
442
443 #ifdef YYTYPE_INT16
444 typedef YYTYPE_INT16 yytype_int16;
445 #else
446 typedef short int yytype_int16;
447 #endif
448
449 #ifndef YYSIZE_T
450 # ifdef __SIZE_TYPE__
451 #  define YYSIZE_T __SIZE_TYPE__
452 # elif defined size_t
453 #  define YYSIZE_T size_t
454 # elif ! defined YYSIZE_T && (defined __STDC__ || defined __C99__FUNC__ \
455      || defined __cplusplus || defined _MSC_VER)
456 #  include <stddef.h> /* INFRINGES ON USER NAME SPACE */
457 #  define YYSIZE_T size_t
458 # else
459 #  define YYSIZE_T unsigned int
460 # endif
461 #endif
462
463 #define YYSIZE_MAXIMUM ((YYSIZE_T) -1)
464
465 #ifndef YY_
466 # if defined YYENABLE_NLS && YYENABLE_NLS
467 #  if ENABLE_NLS
468 #   include <libintl.h> /* INFRINGES ON USER NAME SPACE */
469 #   define YY_(msgid) dgettext ("bison-runtime", msgid)
470 #  endif
471 # endif
472 # ifndef YY_
473 #  define YY_(msgid) msgid
474 # endif
475 #endif
476
477 /* Suppress unused-variable warnings by "using" E.  */
478 #if ! defined lint || defined __GNUC__
479 # define YYUSE(e) ((void) (e))
480 #else
481 # define YYUSE(e) /* empty */
482 #endif
483
484 /* Identity function, used to suppress warnings about constant conditions.  */
485 #ifndef lint
486 # define YYID(n) (n)
487 #else
488 #if (defined __STDC__ || defined __C99__FUNC__ \
489      || defined __cplusplus || defined _MSC_VER)
490 static int
491 YYID (int i)
492 #else
493 static int
494 YYID (i)
495     int i;
496 #endif
497 {
498   return i;
499 }
500 #endif
501
502 #if ! defined yyoverflow || YYERROR_VERBOSE
503
504 /* The parser invokes alloca or malloc; define the necessary symbols.  */
505
506 # ifdef YYSTACK_USE_ALLOCA
507 #  if YYSTACK_USE_ALLOCA
508 #   ifdef __GNUC__
509 #    define YYSTACK_ALLOC __builtin_alloca
510 #   elif defined __BUILTIN_VA_ARG_INCR
511 #    include <alloca.h> /* INFRINGES ON USER NAME SPACE */
512 #   elif defined _AIX
513 #    define YYSTACK_ALLOC __alloca
514 #   elif defined _MSC_VER
515 #    include <malloc.h> /* INFRINGES ON USER NAME SPACE */
516 #    define alloca _alloca
517 #   else
518 #    define YYSTACK_ALLOC alloca
519 #    if ! defined _ALLOCA_H && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \
520      || defined __cplusplus || defined _MSC_VER)
521 #     include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
522 #     ifndef _STDLIB_H
523 #      define _STDLIB_H 1
524 #     endif
525 #    endif
526 #   endif
527 #  endif
528 # endif
529
530 # ifdef YYSTACK_ALLOC
531    /* Pacify GCC's `empty if-body' warning.  */
532 #  define YYSTACK_FREE(Ptr) do { /* empty */; } while (YYID (0))
533 #  ifndef YYSTACK_ALLOC_MAXIMUM
534     /* The OS might guarantee only one guard page at the bottom of the stack,
535        and a page size can be as small as 4096 bytes.  So we cannot safely
536        invoke alloca (N) if N exceeds 4096.  Use a slightly smaller number
537        to allow for a few compiler-allocated temporary stack slots.  */
538 #   define YYSTACK_ALLOC_MAXIMUM 4032 /* reasonable circa 2006 */
539 #  endif
540 # else
541 #  define YYSTACK_ALLOC YYMALLOC
542 #  define YYSTACK_FREE YYFREE
543 #  ifndef YYSTACK_ALLOC_MAXIMUM
544 #   define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM
545 #  endif
546 #  if (defined __cplusplus && ! defined _STDLIB_H \
547        && ! ((defined YYMALLOC || defined malloc) \
548              && (defined YYFREE || defined free)))
549 #   include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
550 #   ifndef _STDLIB_H
551 #    define _STDLIB_H 1
552 #   endif
553 #  endif
554 #  ifndef YYMALLOC
555 #   define YYMALLOC malloc
556 #   if ! defined malloc && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \
557      || defined __cplusplus || defined _MSC_VER)
558 void *malloc (YYSIZE_T); /* INFRINGES ON USER NAME SPACE */
559 #   endif
560 #  endif
561 #  ifndef YYFREE
562 #   define YYFREE free
563 #   if ! defined free && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \
564      || defined __cplusplus || defined _MSC_VER)
565 void free (void *); /* INFRINGES ON USER NAME SPACE */
566 #   endif
567 #  endif
568 # endif
569 #endif /* ! defined yyoverflow || YYERROR_VERBOSE */
570
571
572 #if (! defined yyoverflow \
573      && (! defined __cplusplus \
574          || (defined YYSTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL)))
575
576 /* A type that is properly aligned for any stack member.  */
577 union yyalloc
578 {
579   yytype_int16 yyss;
580   YYSTYPE yyvs;
581   };
582
583 /* The size of the maximum gap between one aligned stack and the next.  */
584 # define YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1)
585
586 /* The size of an array large to enough to hold all stacks, each with
587    N elements.  */
588 # define YYSTACK_BYTES(N) \
589      ((N) * (sizeof (yytype_int16) + sizeof (YYSTYPE)) \
590       + YYSTACK_GAP_MAXIMUM)
591
592 /* Copy COUNT objects from FROM to TO.  The source and destination do
593    not overlap.  */
594 # ifndef YYCOPY
595 #  if defined __GNUC__ && 1 < __GNUC__
596 #   define YYCOPY(To, From, Count) \
597       __builtin_memcpy (To, From, (Count) * sizeof (*(From)))
598 #  else
599 #   define YYCOPY(To, From, Count)              \
600       do                                        \
601         {                                       \
602           YYSIZE_T yyi;                         \
603           for (yyi = 0; yyi < (Count); yyi++)   \
604             (To)[yyi] = (From)[yyi];            \
605         }                                       \
606       while (YYID (0))
607 #  endif
608 # endif
609
610 /* Relocate STACK from its old location to the new one.  The
611    local variables YYSIZE and YYSTACKSIZE give the old and new number of
612    elements in the stack, and YYPTR gives the new location of the
613    stack.  Advance YYPTR to a properly aligned location for the next
614    stack.  */
615 # define YYSTACK_RELOCATE(Stack)                                        \
616     do                                                                  \
617       {                                                                 \
618         YYSIZE_T yynewbytes;                                            \
619         YYCOPY (&yyptr->Stack, Stack, yysize);                          \
620         Stack = &yyptr->Stack;                                          \
621         yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \
622         yyptr += yynewbytes / sizeof (*yyptr);                          \
623       }                                                                 \
624     while (YYID (0))
625
626 #endif
627
628 /* YYFINAL -- State number of the termination state.  */
629 #define YYFINAL  2
630 /* YYLAST -- Last index in YYTABLE.  */
631 #define YYLAST   830
632
633 /* YYNTOKENS -- Number of terminals.  */
634 #define YYNTOKENS  112
635 /* YYNNTS -- Number of nonterminals.  */
636 #define YYNNTS  102
637 /* YYNRULES -- Number of rules.  */
638 #define YYNRULES  276
639 /* YYNRULES -- Number of states.  */
640 #define YYNSTATES  520
641
642 /* YYTRANSLATE(YYLEX) -- Bison symbol number corresponding to YYLEX.  */
643 #define YYUNDEFTOK  2
644 #define YYMAXUTOK   353
645
646 #define YYTRANSLATE(YYX)                                                \
647   ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK)
648
649 /* YYTRANSLATE[YYLEX] -- Bison symbol number corresponding to YYLEX.  */
650 static const yytype_uint8 yytranslate[] =
651 {
652        0,     2,     2,     2,     2,     2,     2,     2,     2,     2,
653        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
654        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
655        2,     2,     2,     2,     2,     2,     2,   105,   100,     2,
656      110,   111,   103,   101,   108,   102,     2,   104,     2,     2,
657        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
658        2,   109,     2,     2,     2,     2,     2,     2,     2,     2,
659        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
660        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
661        2,     2,     2,     2,    99,     2,     2,     2,     2,     2,
662        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
663        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
664        2,     2,     2,     2,    98,     2,   106,     2,     2,     2,
665        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
666        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
667        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
668        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
669        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
670        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
671        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
672        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
673        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
674        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
675        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
676        2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
677        2,     2,     2,     2,     2,     2,     1,     2,     3,     4,
678        5,     6,     7,     8,     9,    10,    11,    12,    13,    14,
679       15,    16,    17,    18,    19,    20,    21,    22,    23,    24,
680       25,    26,    27,    28,    29,    30,    31,    32,    33,    34,
681       35,    36,    37,    38,    39,    40,    41,    42,    43,    44,
682       45,    46,    47,    48,    49,    50,    51,    52,    53,    54,
683       55,    56,    57,    58,    59,    60,    61,    62,    63,    64,
684       65,    66,    67,    68,    69,    70,    71,    72,    73,    74,
685       75,    76,    77,    78,    79,    80,    81,    82,    83,    84,
686       85,    86,    87,    88,    89,    90,    91,    92,    93,    94,
687       95,    96,    97,   107
688 };
689
690 #if YYDEBUG
691 /* YYPRHS[YYN] -- Index of the first RHS symbol of rule number YYN in
692    YYRHS.  */
693 static const yytype_uint16 yyprhs[] =
694 {
695        0,     0,     3,     4,     7,    10,    13,    16,    19,    22,
696       25,    28,    31,    34,    37,    40,    43,    46,    49,    56,
697       57,    60,    63,    68,    70,    72,    74,    78,    81,    83,
698       85,    87,    89,    91,    93,    98,   103,   104,   118,   119,
699      133,   134,   149,   150,   154,   155,   159,   163,   167,   171,
700      175,   181,   188,   196,   205,   209,   213,   218,   222,   223,
701      226,   227,   232,   233,   238,   239,   244,   245,   250,   251,
702      256,   257,   261,   273,   286,   287,   292,   293,   298,   299,
703      303,   304,   309,   310,   315,   322,   331,   342,   354,   355,
704      360,   361,   365,   366,   371,   372,   377,   378,   383,   384,
705      389,   390,   395,   396,   400,   401,   406,   407,   423,   430,
706      439,   449,   452,   453,   456,   458,   460,   461,   465,   466,
707      470,   471,   475,   476,   480,   485,   490,   494,   501,   502,
708      505,   510,   513,   520,   521,   525,   528,   530,   532,   534,
709      536,   538,   540,   547,   548,   551,   554,   558,   564,   567,
710      573,   580,   588,   598,   603,   604,   607,   608,   610,   612,
711      614,   616,   620,   624,   628,   631,   632,   639,   640,   644,
712      649,   652,   654,   656,   658,   660,   662,   664,   666,   668,
713      670,   672,   679,   684,   693,   694,   698,   701,   708,   709,
714      716,   723,   727,   731,   735,   739,   743,   744,   750,   758,
715      759,   765,   766,   772,   773,   777,   779,   781,   783,   785,
716      788,   790,   793,   794,   797,   801,   806,   810,   811,   814,
717      815,   818,   820,   822,   824,   826,   828,   830,   832,   834,
718      836,   838,   841,   843,   845,   847,   849,   851,   854,   856,
719      859,   861,   864,   866,   869,   873,   878,   880,   884,   885,
720      887,   890,   892,   894,   898,   901,   904,   908,   912,   916,
721      920,   924,   928,   932,   936,   939,   941,   943,   947,   950,
722      954,   958,   962,   966,   970,   974,   978
723 };
724
725 /* YYRHS -- A `-1'-separated list of the rules' RHS.  */
726 static const yytype_int16 yyrhs[] =
727 {
728      113,     0,    -1,    -1,   113,   114,    -1,   113,   120,    -1,
729      113,   121,    -1,   113,   122,    -1,   113,   162,    -1,   113,
730      163,    -1,   113,   164,    -1,   113,   165,    -1,   113,   170,
731       -1,   113,   173,    -1,   113,   178,    -1,   113,   183,    -1,
732      113,   182,    -1,   113,   185,    -1,   113,    97,    -1,   191,
733        5,   194,     3,   115,     4,    -1,    -1,   115,   116,    -1,
734      117,   211,    -1,   117,   211,   108,   118,    -1,    92,    -1,
735      212,    -1,   119,    -1,   118,   108,   119,    -1,   118,   119,
736       -1,     6,    -1,     7,    -1,     8,    -1,     9,    -1,    10,
737       -1,    11,    -1,   191,    12,   196,   198,    -1,   191,    13,
738      195,   198,    -1,    -1,   191,    14,   196,   126,   212,   208,
739      208,   208,   123,   127,     3,   128,     4,    -1,    -1,   191,
740       15,   196,   126,   212,   208,   208,   208,   124,   127,     3,
741      128,     4,    -1,    -1,   191,    15,   196,   126,   212,   208,
742      208,   208,   208,   125,   127,     3,   128,     4,    -1,    -1,
743       16,   109,   209,    -1,    -1,   127,    17,   199,    -1,   127,
744       18,   191,    -1,   127,    19,   205,    -1,   127,    16,   209,
745       -1,   127,    18,   199,    -1,   127,    41,   209,   108,   199,
746       -1,   127,    41,   209,   108,   199,   208,    -1,   127,    41,
747      209,   108,   199,   208,   208,    -1,   127,    41,   209,   108,
748      199,   208,   208,   208,    -1,   127,    57,   191,    -1,   127,
749       55,   209,    -1,   127,    54,   209,   208,    -1,   127,    56,
750      209,    -1,    -1,   128,   129,    -1,    -1,    20,   153,   130,
751      151,    -1,    -1,    21,   153,   131,   151,    -1,    -1,    22,
752      153,   132,   151,    -1,    -1,    38,   153,   133,   151,    -1,
753       -1,    23,   153,   134,   151,    -1,    -1,    24,   135,   151,
754       -1,    10,   153,   209,   152,   156,   208,   208,   208,   208,
755      207,   155,    -1,    10,   153,   209,   152,   156,   208,   208,
756      208,   208,   208,   208,   155,    -1,    -1,    25,   153,   136,
757      151,    -1,    -1,    26,   153,   137,   151,    -1,    -1,    27,
758      138,   151,    -1,    -1,    28,   153,   139,   151,    -1,    -1,
759       39,   153,   140,   151,    -1,    42,   193,   209,   208,   208,
760      155,    -1,    42,   193,   209,   208,   208,   208,   208,   155,
761       -1,    42,   193,   209,   208,   208,   208,   208,   158,   207,
762      155,    -1,    42,   193,   209,   208,   208,   208,   208,   158,
763      208,   208,   155,    -1,    -1,    40,   153,   141,   151,    -1,
764       -1,    29,   142,   151,    -1,    -1,    30,   153,   143,   151,
765       -1,    -1,    31,   153,   144,   151,    -1,    -1,    32,   153,
766      145,   151,    -1,    -1,    33,   153,   146,   151,    -1,    -1,
767       34,   153,   147,   151,    -1,    -1,    35,   148,   151,    -1,
768       -1,    36,   153,   149,   151,    -1,    -1,    37,   193,   209,
769      108,   209,   108,   209,   108,   209,   108,   209,   108,   150,
770      205,   207,    -1,   209,   208,   208,   208,   208,   155,    -1,
771      209,   208,   208,   208,   208,   160,   207,   155,    -1,   209,
772      208,   208,   208,   208,   160,   208,   208,   155,    -1,   108,
773      154,    -1,    -1,   154,   108,    -1,   212,    -1,   199,    -1,
774       -1,     3,   174,     4,    -1,    -1,   108,   157,   205,    -1,
775       -1,   108,   159,   205,    -1,    -1,   108,   161,   205,    -1,
776      191,    41,   195,   198,    -1,   191,    42,   195,   198,    -1,
777       54,   209,   208,    -1,   191,    57,   194,     3,   166,     4,
778       -1,    -1,   166,   167,    -1,    59,   199,   208,   168,    -1,
779       59,    60,    -1,    61,   199,   168,     3,   166,     4,    -1,
780       -1,   168,   108,   169,    -1,   168,   169,    -1,    62,    -1,
781       63,    -1,    64,    -1,    65,    -1,    66,    -1,    67,    -1,
782      191,    58,   194,     3,   171,     4,    -1,    -1,   171,   172,
783       -1,    59,   199,    -1,    59,   199,   208,    -1,    59,   199,
784      208,   208,   207,    -1,    59,    60,    -1,    61,   199,     3,
785      171,     4,    -1,    61,   199,   208,     3,   171,     4,    -1,
786       61,   199,   208,   208,     3,   171,     4,    -1,    61,   199,
787      208,   208,   208,   207,     3,   171,     4,    -1,   191,    68,
788      196,   198,    -1,    -1,   175,   176,    -1,    -1,   177,    -1,
789      203,    -1,   204,    -1,   210,    -1,   177,   108,   203,    -1,
790      177,   108,   204,    -1,   177,   108,   210,    -1,   177,   108,
791       -1,    -1,    70,   194,     3,   179,   180,     4,    -1,    -1,
792      180,   209,   202,    -1,   180,   209,   108,   202,    -1,   180,
793        1,    -1,   191,    -1,    48,    -1,    69,    -1,    49,    -1,
794       50,    -1,    51,    -1,    45,    -1,    46,    -1,    43,    -1,
795       44,    -1,   191,   181,   194,     3,   174,     4,    -1,   191,
796      181,   194,   198,    -1,   191,    52,   194,   209,   208,     3,
797      184,     4,    -1,    -1,   184,    53,   191,    -1,   184,    60,
798       -1,   191,    71,   186,     3,   187,     4,    -1,    -1,   186,
799       72,   209,   207,   207,   207,    -1,   186,    73,   209,   207,
800      207,   207,    -1,   186,    74,   209,    -1,   186,    75,   209,
801       -1,   186,    76,   209,    -1,   186,    77,   209,    -1,   186,
802       78,   209,    -1,    -1,   187,    79,     3,   188,     4,    -1,
803      187,    80,     3,    81,   199,   190,     4,    -1,    -1,   188,
804       82,     3,   189,     4,    -1,    -1,   189,    81,   199,   108,
805      199,    -1,    -1,   190,   208,   208,    -1,   212,    -1,   192,
806       -1,   200,    -1,    93,    -1,   212,   108,    -1,   192,    -1,
807      192,   108,    -1,    -1,   194,   197,    -1,   194,    55,   209,
808       -1,   194,    54,   209,   208,    -1,   194,    56,   209,    -1,
809       -1,   195,   197,    -1,    -1,   196,   197,    -1,    83,    -1,
810       84,    -1,    85,    -1,    86,    -1,    87,    -1,    88,    -1,
811       89,    -1,    92,    -1,    93,    -1,   200,    -1,   199,   200,
812       -1,    91,    -1,    92,    -1,   204,    -1,   203,    -1,   201,
813       -1,   202,   201,    -1,    96,    -1,   203,    96,    -1,    95,
814       -1,   204,    95,    -1,   206,    -1,    90,   206,    -1,   205,
815       98,   206,    -1,   205,    98,    90,   206,    -1,    94,    -1,
816      110,   209,   111,    -1,    -1,   208,    -1,   108,   209,    -1,
817      210,    -1,    94,    -1,   110,   210,   111,    -1,   106,   210,
818       -1,   102,   210,    -1,   210,   103,   210,    -1,   210,   104,
819      210,    -1,   210,   105,   210,    -1,   210,   101,   210,    -1,
820      210,   102,   210,    -1,   210,   100,   210,    -1,   210,    99,
821      210,    -1,   210,    98,   210,    -1,   108,   212,    -1,   213,
822       -1,    94,    -1,   110,   210,   111,    -1,   106,   210,    -1,
823      213,   103,   210,    -1,   213,   104,   210,    -1,   213,   105,
824      210,    -1,   213,   101,   210,    -1,   213,   102,   210,    -1,
825      213,   100,   210,    -1,   213,    99,   210,    -1,   213,    98,
826      210,    -1
827 };
828
829 /* YYRLINE[YYN] -- source line where rule number YYN was defined.  */
830 static const yytype_uint16 yyrline[] =
831 {
832        0,   178,   178,   180,   181,   182,   183,   184,   185,   186,
833      187,   188,   189,   190,   191,   192,   193,   194,   200,   211,
834      214,   235,   240,   252,   272,   282,   286,   291,   298,   302,
835      307,   311,   315,   319,   328,   340,   354,   352,   379,   377,
836      406,   404,   436,   439,   445,   447,   453,   457,   462,   466,
837      470,   483,   498,   513,   528,   532,   536,   540,   546,   548,
838      560,   559,   572,   571,   584,   583,   596,   595,   611,   610,
839      623,   622,   636,   647,   657,   656,   669,   668,   681,   680,
840      693,   692,   705,   704,   719,   724,   730,   736,   743,   742,
841      758,   757,   770,   769,   782,   781,   793,   792,   805,   804,
842      817,   816,   829,   828,   841,   840,   854,   852,   873,   884,
843      895,   907,   918,   921,   925,   930,   940,   943,   953,   952,
844      959,   958,   965,   964,   972,   984,   997,  1006,  1017,  1020,
845     1037,  1041,  1045,  1053,  1056,  1060,  1067,  1071,  1075,  1079,
846     1083,  1087,  1096,  1107,  1110,  1127,  1131,  1135,  1139,  1143,
847     1147,  1151,  1155,  1165,  1178,  1178,  1190,  1194,  1201,  1209,
848     1217,  1225,  1234,  1243,  1252,  1262,  1261,  1266,  1268,  1273,
849     1278,  1286,  1290,  1295,  1300,  1305,  1310,  1315,  1320,  1325,
850     1330,  1341,  1348,  1358,  1364,  1365,  1384,  1409,  1420,  1425,
851     1432,  1439,  1444,  1449,  1454,  1459,  1474,  1477,  1481,  1489,
852     1492,  1500,  1503,  1511,  1514,  1523,  1528,  1537,  1541,  1551,
853     1556,  1560,  1571,  1577,  1583,  1588,  1593,  1604,  1609,  1621,
854     1626,  1638,  1643,  1648,  1653,  1658,  1663,  1668,  1678,  1682,
855     1690,  1695,  1710,  1714,  1723,  1727,  1739,  1744,  1760,  1764,
856     1776,  1780,  1802,  1806,  1810,  1814,  1821,  1825,  1835,  1838,
857     1847,  1856,  1865,  1869,  1873,  1878,  1883,  1888,  1893,  1898,
858     1903,  1908,  1913,  1918,  1929,  1938,  1949,  1953,  1957,  1962,
859     1967,  1972,  1977,  1982,  1987,  1992,  1997
860 };
861 #endif
862
863 #if YYDEBUG || YYERROR_VERBOSE || YYTOKEN_TABLE
864 /* YYTNAME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM.
865    First, the terminals, then, starting at YYNTOKENS, nonterminals.  */
866 static const char *const yytname[] =
867 {
868   "$end", "error", "$undefined", "BEG", "END", "ACCELERATORS", "VIRTKEY",
869   "ASCII", "NOINVERT", "SHIFT", "CONTROL", "ALT", "BITMAP", "CURSOR",
870   "DIALOG", "DIALOGEX", "EXSTYLE", "CAPTION", "CLASS", "STYLE",
871   "AUTO3STATE", "AUTOCHECKBOX", "AUTORADIOBUTTON", "CHECKBOX", "COMBOBOX",
872   "CTEXT", "DEFPUSHBUTTON", "EDITTEXT", "GROUPBOX", "LISTBOX", "LTEXT",
873   "PUSHBOX", "PUSHBUTTON", "RADIOBUTTON", "RTEXT", "SCROLLBAR", "STATE3",
874   "USERBUTTON", "BEDIT", "HEDIT", "IEDIT", "FONT", "ICON", "ANICURSOR",
875   "ANIICON", "DLGINCLUDE", "DLGINIT", "FONTDIR", "HTML", "MANIFEST",
876   "PLUGPLAY", "VXD", "TOOLBAR", "BUTTON", "LANGUAGE", "CHARACTERISTICS",
877   "VERSIONK", "MENU", "MENUEX", "MENUITEM", "SEPARATOR", "POPUP",
878   "CHECKED", "GRAYED", "HELP", "INACTIVE", "MENUBARBREAK", "MENUBREAK",
879   "MESSAGETABLE", "RCDATA", "STRINGTABLE", "VERSIONINFO", "FILEVERSION",
880   "PRODUCTVERSION", "FILEFLAGSMASK", "FILEFLAGS", "FILEOS", "FILETYPE",
881   "FILESUBTYPE", "BLOCKSTRINGFILEINFO", "BLOCKVARFILEINFO", "VALUE",
882   "BLOCK", "MOVEABLE", "FIXED", "PURE", "IMPURE", "PRELOAD", "LOADONCALL",
883   "DISCARDABLE", "NOT", "QUOTEDUNISTRING", "QUOTEDSTRING", "STRING",
884   "NUMBER", "SIZEDUNISTRING", "SIZEDSTRING", "IGNORED_TOKEN", "'|'", "'^'",
885   "'&'", "'+'", "'-'", "'*'", "'/'", "'%'", "'~'", "NEG", "','", "'='",
886   "'('", "')'", "$accept", "input", "accelerator", "acc_entries",
887   "acc_entry", "acc_event", "acc_options", "acc_option", "bitmap",
888   "cursor", "dialog", "@1", "@2", "@3", "exstyle", "styles", "controls",
889   "control", "@4", "@5", "@6", "@7", "@8", "@9", "@10", "@11", "@12",
890   "@13", "@14", "@15", "@16", "@17", "@18", "@19", "@20", "@21", "@22",
891   "@23", "@24", "control_params", "cresid", "optresidc", "resid",
892   "opt_control_data", "control_styleexpr", "@25", "icon_styleexpr", "@26",
893   "control_params_styleexpr", "@27", "font", "icon", "language", "menu",
894   "menuitems", "menuitem", "menuitem_flags", "menuitem_flag", "menuex",
895   "menuexitems", "menuexitem", "messagetable", "optrcdata_data", "@28",
896   "optrcdata_data_int", "rcdata_data", "stringtable", "@29", "string_data",
897   "rcdata_id", "user", "toolbar", "toolbar_data", "versioninfo",
898   "fixedverinfo", "verblocks", "verstringtables", "vervals", "vertrans",
899   "id", "resname", "resref", "suboptions", "memflags_move_discard",
900   "memflags_move", "memflag", "file_name", "res_unicode_string_concat",
901   "res_unicode_string", "res_unicode_sizedstring",
902   "res_unicode_sizedstring_concat", "sizedstring", "sizedunistring",
903   "styleexpr", "parennumber", "optcnumexpr", "cnumexpr", "numexpr",
904   "sizednumexpr", "cposnumexpr", "posnumexpr", "sizedposnumexpr", 0
905 };
906 #endif
907
908 # ifdef YYPRINT
909 /* YYTOKNUM[YYLEX-NUM] -- Internal token number corresponding to
910    token YYLEX-NUM.  */
911 static const yytype_uint16 yytoknum[] =
912 {
913        0,   256,   257,   258,   259,   260,   261,   262,   263,   264,
914      265,   266,   267,   268,   269,   270,   271,   272,   273,   274,
915      275,   276,   277,   278,   279,   280,   281,   282,   283,   284,
916      285,   286,   287,   288,   289,   290,   291,   292,   293,   294,
917      295,   296,   297,   298,   299,   300,   301,   302,   303,   304,
918      305,   306,   307,   308,   309,   310,   311,   312,   313,   314,
919      315,   316,   317,   318,   319,   320,   321,   322,   323,   324,
920      325,   326,   327,   328,   329,   330,   331,   332,   333,   334,
921      335,   336,   337,   338,   339,   340,   341,   342,   343,   344,
922      345,   346,   347,   348,   349,   350,   351,   352,   124,    94,
923       38,    43,    45,    42,    47,    37,   126,   353,    44,    61,
924       40,    41
925 };
926 # endif
927
928 /* YYR1[YYN] -- Symbol number of symbol that rule YYN derives.  */
929 static const yytype_uint8 yyr1[] =
930 {
931        0,   112,   113,   113,   113,   113,   113,   113,   113,   113,
932      113,   113,   113,   113,   113,   113,   113,   113,   114,   115,
933      115,   116,   116,   117,   117,   118,   118,   118,   119,   119,
934      119,   119,   119,   119,   120,   121,   123,   122,   124,   122,
935      125,   122,   126,   126,   127,   127,   127,   127,   127,   127,
936      127,   127,   127,   127,   127,   127,   127,   127,   128,   128,
937      130,   129,   131,   129,   132,   129,   133,   129,   134,   129,
938      135,   129,   129,   129,   136,   129,   137,   129,   138,   129,
939      139,   129,   140,   129,   129,   129,   129,   129,   141,   129,
940      142,   129,   143,   129,   144,   129,   145,   129,   146,   129,
941      147,   129,   148,   129,   149,   129,   150,   129,   151,   151,
942      151,   152,   153,   153,   154,   154,   155,   155,   157,   156,
943      159,   158,   161,   160,   162,   163,   164,   165,   166,   166,
944      167,   167,   167,   168,   168,   168,   169,   169,   169,   169,
945      169,   169,   170,   171,   171,   172,   172,   172,   172,   172,
946      172,   172,   172,   173,   175,   174,   176,   176,   177,   177,
947      177,   177,   177,   177,   177,   179,   178,   180,   180,   180,
948      180,   181,   181,   181,   181,   181,   181,   181,   181,   181,
949      181,   182,   182,   183,   184,   184,   184,   185,   186,   186,
950      186,   186,   186,   186,   186,   186,   187,   187,   187,   188,
951      188,   189,   189,   190,   190,   191,   191,   192,   192,   193,
952      193,   193,   194,   194,   194,   194,   194,   195,   195,   196,
953      196,   197,   197,   197,   197,   197,   197,   197,   198,   198,
954      199,   199,   200,   200,   201,   201,   202,   202,   203,   203,
955      204,   204,   205,   205,   205,   205,   206,   206,   207,   207,
956      208,   209,   210,   210,   210,   210,   210,   210,   210,   210,
957      210,   210,   210,   210,   211,   212,   213,   213,   213,   213,
958      213,   213,   213,   213,   213,   213,   213
959 };
960
961 /* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN.  */
962 static const yytype_uint8 yyr2[] =
963 {
964        0,     2,     0,     2,     2,     2,     2,     2,     2,     2,
965        2,     2,     2,     2,     2,     2,     2,     2,     6,     0,
966        2,     2,     4,     1,     1,     1,     3,     2,     1,     1,
967        1,     1,     1,     1,     4,     4,     0,    13,     0,    13,
968        0,    14,     0,     3,     0,     3,     3,     3,     3,     3,
969        5,     6,     7,     8,     3,     3,     4,     3,     0,     2,
970        0,     4,     0,     4,     0,     4,     0,     4,     0,     4,
971        0,     3,    11,    12,     0,     4,     0,     4,     0,     3,
972        0,     4,     0,     4,     6,     8,    10,    11,     0,     4,
973        0,     3,     0,     4,     0,     4,     0,     4,     0,     4,
974        0,     4,     0,     3,     0,     4,     0,    15,     6,     8,
975        9,     2,     0,     2,     1,     1,     0,     3,     0,     3,
976        0,     3,     0,     3,     4,     4,     3,     6,     0,     2,
977        4,     2,     6,     0,     3,     2,     1,     1,     1,     1,
978        1,     1,     6,     0,     2,     2,     3,     5,     2,     5,
979        6,     7,     9,     4,     0,     2,     0,     1,     1,     1,
980        1,     3,     3,     3,     2,     0,     6,     0,     3,     4,
981        2,     1,     1,     1,     1,     1,     1,     1,     1,     1,
982        1,     6,     4,     8,     0,     3,     2,     6,     0,     6,
983        6,     3,     3,     3,     3,     3,     0,     5,     7,     0,
984        5,     0,     5,     0,     3,     1,     1,     1,     1,     2,
985        1,     2,     0,     2,     3,     4,     3,     0,     2,     0,
986        2,     1,     1,     1,     1,     1,     1,     1,     1,     1,
987        1,     2,     1,     1,     1,     1,     1,     2,     1,     2,
988        1,     2,     1,     2,     3,     4,     1,     3,     0,     1,
989        2,     1,     1,     3,     2,     2,     3,     3,     3,     3,
990        3,     3,     3,     3,     2,     1,     1,     3,     2,     3,
991        3,     3,     3,     3,     3,     3,     3
992 };
993
994 /* YYDEFACT[STATE-NAME] -- Default rule to reduce with in state
995    STATE-NUM when YYTABLE doesn't specify something else to do.  Zero
996    means the default is an error.  */
997 static const yytype_uint16 yydefact[] =
998 {
999        2,     0,     1,     0,   212,   232,   233,   208,   266,    17,
1000        0,     0,     3,     4,     5,     6,     7,     8,     9,    10,
1001       11,    12,    13,    15,    14,    16,     0,   206,   207,   205,
1002      265,   252,     0,     0,     0,     0,   251,     0,   268,     0,
1003      212,   219,   217,   219,   219,   217,   217,   179,   180,   177,
1004      178,   172,   174,   175,   176,   212,   212,   212,   219,   173,
1005      188,   212,   171,     0,     0,     0,     0,     0,     0,     0,
1006        0,   255,   254,     0,     0,   126,     0,     0,     0,     0,
1007        0,     0,     0,     0,   165,     0,     0,     0,   221,   222,
1008      223,   224,   225,   226,   227,   213,   267,     0,     0,     0,
1009       42,    42,     0,     0,     0,     0,     0,     0,     0,     0,
1010      276,   275,   274,   272,   273,   269,   270,   271,   253,   250,
1011      263,   262,   261,   259,   260,   256,   257,   258,   167,     0,
1012      214,   216,    19,   228,   229,   220,    34,   218,    35,     0,
1013        0,     0,   124,   125,     0,   128,   143,   153,   196,     0,
1014        0,     0,     0,     0,     0,     0,   154,   182,     0,   215,
1015        0,     0,     0,     0,     0,     0,     0,     0,   248,   248,
1016      191,   192,   193,   194,   195,     0,   156,   170,   166,     0,
1017       18,    23,    20,     0,    24,    43,     0,     0,   184,   127,
1018        0,     0,   129,   142,     0,     0,   144,   187,     0,     0,
1019      248,   249,   248,   181,   240,   238,   155,   157,   158,   159,
1020      160,     0,   236,   168,   235,   234,     0,    21,     0,     0,
1021        0,   131,     0,   230,   133,   148,   145,     0,   199,     0,
1022      248,   248,   164,   239,   241,   169,   237,   264,     0,    36,
1023       38,   183,     0,   186,   231,   133,     0,   146,   143,     0,
1024        0,     0,   189,   190,   161,   162,   163,    28,    29,    30,
1025       31,    32,    33,    22,    25,    44,    44,    40,   185,   130,
1026      128,   136,   137,   138,   139,   140,   141,     0,   135,   248,
1027        0,   143,     0,   197,     0,   203,     0,    27,     0,     0,
1028       44,     0,   134,   147,   149,     0,   143,   248,   201,     0,
1029       26,    58,     0,     0,     0,     0,     0,     0,     0,     0,
1030        0,    58,     0,   132,   150,     0,     0,     0,   198,     0,
1031        0,    48,    45,    46,    49,   207,     0,   246,     0,    47,
1032      242,     0,     0,    55,    57,    54,     0,    58,   151,   143,
1033      200,     0,   204,    37,   112,   112,   112,   112,   112,    70,
1034      112,   112,    78,   112,    90,   112,   112,   112,   112,   112,
1035      102,   112,     0,   112,   112,   112,     0,    59,   243,     0,
1036        0,     0,    56,    39,     0,     0,     0,     0,     0,   115,
1037      114,    60,    62,    64,    68,     0,    74,    76,     0,    80,
1038        0,    92,    94,    96,    98,   100,     0,   104,   210,     0,
1039        0,    66,    82,    88,     0,   247,     0,   244,    50,    41,
1040      152,     0,     0,   113,     0,     0,     0,     0,    71,     0,
1041        0,     0,    79,     0,    91,     0,     0,     0,     0,     0,
1042      103,     0,   211,     0,   209,     0,     0,     0,     0,   245,
1043       51,   202,     0,     0,    61,    63,    65,    69,     0,    75,
1044       77,    81,    93,    95,    97,    99,   101,   105,     0,    67,
1045       83,    89,     0,    52,   111,   118,     0,     0,     0,   116,
1046       53,     0,     0,     0,     0,   154,    84,     0,   119,     0,
1047      116,     0,     0,   116,     0,   122,   108,   248,     0,   117,
1048      120,    85,   248,   248,     0,   116,   249,     0,     0,   116,
1049      249,   116,   249,   123,   109,   116,     0,   121,    86,   116,
1050       72,   116,   110,     0,    87,    73,   106,     0,   248,   107
1051 };
1052
1053 /* YYDEFGOTO[NTERM-NUM].  */
1054 static const yytype_int16 yydefgoto[] =
1055 {
1056       -1,     1,    12,   160,   182,   183,   263,   264,    13,    14,
1057       15,   265,   266,   290,   140,   288,   320,   367,   414,   415,
1058      416,   435,   417,   385,   420,   421,   388,   423,   436,   437,
1059      390,   425,   426,   427,   428,   429,   396,   431,   517,   418,
1060      443,   377,   378,   476,   466,   471,   492,   498,   487,   494,
1061       16,    17,    18,    19,   165,   192,   246,   278,    20,   166,
1062      196,    21,   175,   176,   206,   207,    22,   128,   158,    61,
1063       23,    24,   220,    25,   108,   167,   250,   317,   299,    26,
1064       27,   399,    37,    99,    98,    95,   136,   379,   223,   212,
1065      213,   214,   215,   329,   330,   200,   201,   419,    36,   217,
1066      380,    30
1067 };
1068
1069 /* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing
1070    STATE-NUM.  */
1071 #define YYPACT_NINF -446
1072 static const yytype_int16 yypact[] =
1073 {
1074     -446,    75,  -446,   317,  -446,  -446,  -446,  -446,  -446,  -446,
1075      317,   317,  -446,  -446,  -446,  -446,  -446,  -446,  -446,  -446,
1076     -446,  -446,  -446,  -446,  -446,  -446,   463,  -446,  -446,  -446,
1077      589,  -446,   317,   317,   317,   -93,   626,   209,  -446,   437,
1078     -446,  -446,  -446,  -446,  -446,  -446,  -446,  -446,  -446,  -446,
1079     -446,  -446,  -446,  -446,  -446,  -446,  -446,  -446,  -446,  -446,
1080     -446,  -446,  -446,   317,   317,   317,   317,   317,   317,   317,
1081      317,  -446,  -446,   526,   317,  -446,   317,   317,   317,   317,
1082      317,   317,   317,   317,  -446,   317,   317,   317,  -446,  -446,
1083     -446,  -446,  -446,  -446,  -446,  -446,  -446,   267,   675,   675,
1084      275,   275,   675,   675,   491,   404,   441,   675,   168,   256,
1085      719,   379,   397,   213,   213,  -446,  -446,  -446,  -446,  -446,
1086      719,   379,   397,   213,   213,  -446,  -446,  -446,  -446,   -93,
1087     -446,  -446,  -446,  -446,  -446,  -446,  -446,  -446,  -446,   -65,
1088      144,   144,  -446,  -446,   -93,  -446,  -446,  -446,  -446,   317,
1089      317,   317,   317,   317,   317,   317,  -446,  -446,    18,  -446,
1090       21,   317,   -93,   -93,    31,   140,   155,   126,   -93,   -93,
1091     -446,  -446,  -446,  -446,  -446,    47,   177,  -446,  -446,   212,
1092     -446,  -446,  -446,   -34,  -446,  -446,   -93,   -93,  -446,  -446,
1093      -36,    -5,  -446,  -446,   -25,    -5,  -446,  -446,   119,   131,
1094      -93,  -446,   -93,  -446,  -446,  -446,  -446,    54,    68,    84,
1095      626,     2,  -446,     2,    68,    84,   144,    87,   -93,   -93,
1096       25,  -446,    95,  -446,    -5,  -446,    95,    62,  -446,   102,
1097      -93,   -93,   177,  -446,  -446,     2,  -446,  -446,   552,  -446,
1098      -93,  -446,   306,  -446,  -446,  -446,    76,   -93,  -446,     8,
1099        6,    -5,  -446,  -446,    68,    84,   626,  -446,  -446,  -446,
1100     -446,  -446,  -446,   167,  -446,  -446,  -446,  -446,  -446,   271,
1101     -446,  -446,  -446,  -446,  -446,  -446,  -446,   763,  -446,   -93,
1102      161,  -446,    11,  -446,   197,    -5,   552,  -446,   374,   548,
1103     -446,   178,  -446,  -446,  -446,   190,  -446,   -93,  -446,     3,
1104     -446,  -446,   317,    -5,   306,   -47,   317,   317,   317,   317,
1105      306,  -446,   565,  -446,  -446,   194,   201,    -1,  -446,   -93,
1106      639,  -446,    -5,  -446,    -5,   143,   -33,  -446,   317,   110,
1107     -446,   105,   -93,  -446,  -446,  -446,   676,  -446,  -446,  -446,
1108     -446,    -5,  -446,  -446,   311,   311,   311,   311,   311,  -446,
1109      311,   311,  -446,   311,  -446,   311,   311,   311,   311,   311,
1110     -446,   311,   306,   311,   311,   311,   306,  -446,  -446,   104,
1111      -42,    -5,  -446,  -446,   713,   207,    99,   317,   113,    -5,
1112     -446,  -446,  -446,  -446,  -446,   317,  -446,  -446,   317,  -446,
1113      317,  -446,  -446,  -446,  -446,  -446,   317,  -446,   115,   317,
1114      120,  -446,  -446,  -446,   317,  -446,   -33,  -446,    95,  -446,
1115     -446,    -5,   152,  -446,   317,   317,   317,   317,  -446,   -93,
1116      317,   317,  -446,   317,  -446,   317,   317,   317,   317,   317,
1117     -446,   317,  -446,   153,  -446,   317,   317,   317,   -93,  -446,
1118      -93,    -5,   311,   159,  -446,  -446,  -446,  -446,   -93,  -446,
1119     -446,  -446,  -446,  -446,  -446,  -446,  -446,  -446,   317,  -446,
1120     -446,  -446,   -93,   -93,  -446,  -446,   -93,   -93,   173,    15,
1121     -446,   -47,   -93,   -93,   317,  -446,  -446,   -93,   110,   -93,
1122       27,   180,   244,    29,   -93,  -446,  -446,   -93,   317,  -446,
1123     -446,  -446,   -93,   -93,   -47,   273,   -93,   192,   -47,   273,
1124      -93,   273,   -93,   110,  -446,   273,   317,   110,  -446,   273,
1125     -446,   273,  -446,   193,  -446,  -446,  -446,   -47,   -75,  -446
1126 };
1127
1128 /* YYPGOTO[NTERM-NUM].  */
1129 static const yytype_int16 yypgoto[] =
1130 {
1131     -446,  -446,  -446,  -446,  -446,  -446,  -446,  -236,  -446,  -446,
1132     -446,  -446,  -446,  -446,   184,  -262,  -273,  -446,  -446,  -446,
1133     -446,  -446,  -446,  -446,  -446,  -446,  -446,  -446,  -446,  -446,
1134     -446,  -446,  -446,  -446,  -446,  -446,  -446,  -446,  -446,   219,
1135     -446,   442,  -123,   274,  -446,  -446,  -446,  -446,  -446,  -446,
1136     -446,  -446,  -446,  -446,    77,  -446,   101,    88,  -446,  -239,
1137     -446,  -446,  -109,  -446,  -446,  -446,  -446,  -446,  -446,  -446,
1138     -446,  -446,  -446,  -446,  -446,  -446,  -446,  -446,  -446,   -24,
1139     -245,     4,   169,   211,   270,   710,   175,  -178,     5,  -173,
1140      157,  -156,  -122,  -445,  -325,  -161,   -30,    -3,    26,  -446,
1141       20,  -446
1142 };
1143
1144 /* YYTABLE[YYPACT[STATE-NUM]].  What to do in state STATE-NUM.  If
1145    positive, shift that token.  If negative, reduce the rule which
1146    number is the opposite.  If zero, do what YYDEFACT says.
1147    If YYTABLE_NINF, syntax error.  */
1148 #define YYTABLE_NINF -231
1149 static const yytype_int16 yytable[] =
1150 {
1151       35,   368,    62,   340,   289,    75,    28,   318,   202,   280,
1152      283,   281,   222,   224,   296,    74,   226,   227,   475,   177,
1153      208,    29,   178,   370,   221,   180,   478,   287,   312,   241,
1154      475,    28,   475,    74,   188,   225,    38,    39,   336,   230,
1155      236,   231,   295,   326,   161,   407,    29,   327,   406,   503,
1156      300,   203,   327,   507,   209,     5,     6,   315,    71,    72,
1157       73,   327,   236,   328,   374,   248,     5,     6,   328,   252,
1158      253,   119,   518,   285,   216,     2,   254,   328,   242,   270,
1159      341,   439,   129,   130,   131,   243,     5,     6,   284,   110,
1160      111,   112,   113,   114,   115,   116,   117,   204,   205,   159,
1161      375,   144,   120,   121,   122,   123,   124,   125,   126,   127,
1162      255,    74,    31,   181,   164,     8,    74,   398,   293,    74,
1163       32,   398,   228,    74,    33,   322,   324,    10,    34,     3,
1164      197,    11,   186,   187,   229,   485,   316,   490,   271,   272,
1165      273,   274,   275,   276,   189,     4,   168,   169,   170,   171,
1166      172,   173,   174,     5,     6,   179,   218,   219,   185,   193,
1167      162,   163,   232,   376,   233,   294,     5,     6,     7,     8,
1168       74,   148,     9,   257,   258,   259,   260,   261,   262,   234,
1169      184,    10,   313,   251,   277,    11,     5,     6,   239,   240,
1170        5,     6,   245,   408,   314,   238,   247,   249,   338,   190,
1171      298,   191,   210,    74,   339,   198,   199,   411,   370,    97,
1172      267,   410,    84,   371,   194,   405,   195,   279,   268,   282,
1173      194,   413,   195,   432,   104,   105,   106,   244,   434,   244,
1174      109,   244,   244,   441,  -230,  -230,   237,   190,     8,   191,
1175      149,   150,   151,   152,   153,   154,   155,    28,   489,   194,
1176       10,   195,   297,   194,    11,   195,   102,   103,   256,   156,
1177      442,   458,    29,    85,    86,    87,   194,   465,   195,   319,
1178      132,    31,   204,   205,   138,   286,   475,   142,   143,    32,
1179      323,   474,   147,    33,   157,   141,   335,    34,   488,   342,
1180      244,   139,    88,    89,    90,    91,    92,    93,    94,   321,
1181      506,   516,   372,   331,   332,   333,   334,   204,   205,   325,
1182       85,    86,    87,   100,   101,    28,    81,    82,    83,   464,
1183      211,    85,    86,    87,    29,   369,   495,   244,   107,   244,
1184       29,   499,   501,   271,   272,   273,   274,   275,   276,    88,
1185       89,    90,    91,    92,    93,    94,   269,   291,   133,   134,
1186       88,    89,    90,    91,    92,    93,    94,   519,    88,    89,
1187       90,    91,    92,    93,    94,   292,   482,    28,   235,     0,
1188      404,    28,     0,     0,   412,     0,     0,   301,   440,   277,
1189        0,   244,   400,     0,   244,     0,   400,     0,     0,   448,
1190      302,   303,   304,   305,     0,     0,   433,     5,     6,     7,
1191        8,   438,     5,     6,     0,     8,     0,   145,   462,     0,
1192      463,    31,    10,   244,     0,   306,    11,    10,   467,    32,
1193        0,    11,     0,    33,     0,     0,     0,    34,   307,   308,
1194      309,   310,   469,   470,     0,     0,   472,   473,     0,   477,
1195        0,     0,   479,   480,   146,     0,   244,   483,     0,   484,
1196        0,     0,     0,     0,   493,   468,     0,   496,    85,    86,
1197       87,     0,   500,   502,     0,     0,   505,     0,    40,     0,
1198      509,   481,   511,     0,     0,    41,    42,    43,    44,    78,
1199       79,    80,    81,    82,    83,   497,     0,    88,    89,    90,
1200       91,    92,    93,    94,     0,    85,    86,    87,    79,    80,
1201       81,    82,    83,   513,    45,    46,    47,    48,    49,    50,
1202        0,    51,    52,    53,    54,    55,     0,     0,     0,     0,
1203       56,    57,     0,     0,    88,    89,    90,    91,    92,    93,
1204       94,    58,    59,     0,    60,    76,    77,    78,    79,    80,
1205       81,    82,    83,     0,     0,    85,    86,    87,    96,     0,
1206        0,   311,     0,     0,     5,     6,     7,     8,   257,   258,
1207      259,   260,   261,   262,   302,   303,   304,   305,   337,    10,
1208        0,     0,     0,    11,    88,    89,    90,    91,    92,    93,
1209       94,   302,   303,   304,   305,    31,     0,     0,     0,   306,
1210        0,     0,     0,    32,     0,     0,     0,    33,     0,     0,
1211        0,    34,   307,   308,   309,   310,   306,   422,     0,   424,
1212        0,     0,     0,     0,     0,   430,     0,     0,     0,   307,
1213      308,   309,   310,     0,    76,    77,    78,    79,    80,    81,
1214       82,    83,     0,   444,   445,   446,   447,   118,     0,   449,
1215      450,     0,   451,   343,   452,   453,   454,   455,   456,   344,
1216      457,     0,     0,     0,   459,   460,   461,     0,     0,   345,
1217      346,   347,   348,   349,   350,   351,   352,   353,   354,   355,
1218      356,   357,   358,   359,   360,   361,   362,   363,   364,   365,
1219      373,   366,     0,     0,     0,     0,   344,    63,    64,    65,
1220       66,    67,    68,    69,    70,     0,   345,   346,   347,   348,
1221      349,   350,   351,   352,   353,   354,   355,   356,   357,   358,
1222      359,   360,   361,   362,   363,   364,   365,   409,   366,     0,
1223        0,     0,     0,   344,    76,    77,    78,    79,    80,    81,
1224       82,    83,     0,   345,   346,   347,   348,   349,   350,   351,
1225      352,   353,   354,   355,   356,   357,   358,   359,   360,   361,
1226      362,   363,   364,   365,   486,   366,     0,   491,    88,    89,
1227       90,    91,    92,    93,    94,     0,     0,   133,   134,   504,
1228        0,     0,     0,   508,     0,   510,     0,     0,     0,   512,
1229        0,     0,     0,   514,     0,   515,     0,   381,   382,   383,
1230      384,     0,   386,   387,     0,   389,     0,   391,   392,   393,
1231      394,   395,     0,   397,     0,   401,   402,   403,   135,   137,
1232      135,   135,   137,   137,     0,     0,     0,   135,    77,    78,
1233       79,    80,    81,    82,    83,   271,   272,   273,   274,   275,
1234      276
1235 };
1236
1237 static const yytype_int16 yycheck[] =
1238 {
1239        3,   326,    26,     4,   266,    35,     1,     4,   169,   248,
1240        4,     3,   190,   191,     3,   108,   194,   195,     3,     1,
1241      176,     1,     4,    98,    60,     4,   471,   263,   290,     4,
1242        3,    26,     3,   108,     3,    60,    10,    11,   311,   200,
1243      213,   202,   281,    90,   109,   370,    26,    94,    90,   494,
1244      286,     4,    94,   498,   176,    91,    92,   296,    32,    33,
1245       34,    94,   235,   110,   337,     3,    91,    92,   110,   230,
1246      231,    74,   517,   251,   108,     0,   232,   110,    53,     3,
1247       81,   406,    85,    86,    87,    60,    91,    92,    82,    63,
1248       64,    65,    66,    67,    68,    69,    70,    95,    96,   129,
1249      339,   104,    76,    77,    78,    79,    80,    81,    82,    83,
1250      232,   108,    94,    92,   144,    94,   108,   362,   279,   108,
1251      102,   366,     3,   108,   106,   303,   304,   106,   110,    54,
1252        4,   110,   162,   163,     3,   108,   297,   108,    62,    63,
1253       64,    65,    66,    67,     4,    70,   149,   150,   151,   152,
1254      153,   154,   155,    91,    92,   158,   186,   187,   161,     4,
1255      140,   141,   108,   341,    96,     4,    91,    92,    93,    94,
1256      108,     3,    97,     6,     7,     8,     9,    10,    11,    95,
1257      160,   106,     4,    81,   108,   110,    91,    92,   218,   219,
1258       91,    92,   222,   371,     4,   108,   226,   227,     4,    59,
1259        3,    61,   176,   108,     3,    79,    80,   108,    98,    40,
1260      240,     4,     3,   108,    59,   111,    61,   247,   242,   249,
1261       59,   108,    61,   108,    55,    56,    57,   222,   108,   224,
1262       61,   226,   227,   411,    91,    92,   216,    59,    94,    61,
1263       72,    73,    74,    75,    76,    77,    78,   242,     4,    59,
1264      106,    61,   282,    59,   110,    61,    45,    46,   232,     3,
1265      108,   108,   242,    54,    55,    56,    59,   108,    61,   299,
1266        3,    94,    95,    96,    99,   108,     3,   102,   103,   102,
1267      304,   108,   107,   106,   109,   101,   310,   110,   108,   319,
1268      285,    16,    83,    84,    85,    86,    87,    88,    89,   302,
1269      108,   108,   332,   306,   307,   308,   309,    95,    96,   304,
1270       54,    55,    56,    43,    44,   310,   103,   104,   105,   442,
1271      108,    54,    55,    56,   304,   328,   487,   322,    58,   324,
1272      310,   492,   493,    62,    63,    64,    65,    66,    67,    83,
1273       84,    85,    86,    87,    88,    89,   245,   270,    92,    93,
1274       83,    84,    85,    86,    87,    88,    89,   518,    83,    84,
1275       85,    86,    87,    88,    89,   277,   475,   362,   211,    -1,
1276      366,   366,    -1,    -1,   377,    -1,    -1,     3,   408,   108,
1277       -1,   376,   362,    -1,   379,    -1,   366,    -1,    -1,   419,
1278       16,    17,    18,    19,    -1,    -1,   399,    91,    92,    93,
1279       94,   404,    91,    92,    -1,    94,    -1,     3,   438,    -1,
1280      440,    94,   106,   408,    -1,    41,   110,   106,   448,   102,
1281       -1,   110,    -1,   106,    -1,    -1,    -1,   110,    54,    55,
1282       56,    57,   462,   463,    -1,    -1,   466,   467,    -1,   469,
1283       -1,    -1,   472,   473,     3,    -1,   441,   477,    -1,   479,
1284       -1,    -1,    -1,    -1,   484,   458,    -1,   487,    54,    55,
1285       56,    -1,   492,   493,    -1,    -1,   496,    -1,     5,    -1,
1286      500,   474,   502,    -1,    -1,    12,    13,    14,    15,   100,
1287      101,   102,   103,   104,   105,   488,    -1,    83,    84,    85,
1288       86,    87,    88,    89,    -1,    54,    55,    56,   101,   102,
1289      103,   104,   105,   506,    41,    42,    43,    44,    45,    46,
1290       -1,    48,    49,    50,    51,    52,    -1,    -1,    -1,    -1,
1291       57,    58,    -1,    -1,    83,    84,    85,    86,    87,    88,
1292       89,    68,    69,    -1,    71,    98,    99,   100,   101,   102,
1293      103,   104,   105,    -1,    -1,    54,    55,    56,   111,    -1,
1294       -1,     3,    -1,    -1,    91,    92,    93,    94,     6,     7,
1295        8,     9,    10,    11,    16,    17,    18,    19,     3,   106,
1296       -1,    -1,    -1,   110,    83,    84,    85,    86,    87,    88,
1297       89,    16,    17,    18,    19,    94,    -1,    -1,    -1,    41,
1298       -1,    -1,    -1,   102,    -1,    -1,    -1,   106,    -1,    -1,
1299       -1,   110,    54,    55,    56,    57,    41,   388,    -1,   390,
1300       -1,    -1,    -1,    -1,    -1,   396,    -1,    -1,    -1,    54,
1301       55,    56,    57,    -1,    98,    99,   100,   101,   102,   103,
1302      104,   105,    -1,   414,   415,   416,   417,   111,    -1,   420,
1303      421,    -1,   423,     4,   425,   426,   427,   428,   429,    10,
1304      431,    -1,    -1,    -1,   435,   436,   437,    -1,    -1,    20,
1305       21,    22,    23,    24,    25,    26,    27,    28,    29,    30,
1306       31,    32,    33,    34,    35,    36,    37,    38,    39,    40,
1307        4,    42,    -1,    -1,    -1,    -1,    10,    98,    99,   100,
1308      101,   102,   103,   104,   105,    -1,    20,    21,    22,    23,
1309       24,    25,    26,    27,    28,    29,    30,    31,    32,    33,
1310       34,    35,    36,    37,    38,    39,    40,     4,    42,    -1,
1311       -1,    -1,    -1,    10,    98,    99,   100,   101,   102,   103,
1312      104,   105,    -1,    20,    21,    22,    23,    24,    25,    26,
1313       27,    28,    29,    30,    31,    32,    33,    34,    35,    36,
1314       37,    38,    39,    40,   480,    42,    -1,   483,    83,    84,
1315       85,    86,    87,    88,    89,    -1,    -1,    92,    93,   495,
1316       -1,    -1,    -1,   499,    -1,   501,    -1,    -1,    -1,   505,
1317       -1,    -1,    -1,   509,    -1,   511,    -1,   345,   346,   347,
1318      348,    -1,   350,   351,    -1,   353,    -1,   355,   356,   357,
1319      358,   359,    -1,   361,    -1,   363,   364,   365,    98,    99,
1320      100,   101,   102,   103,    -1,    -1,    -1,   107,    99,   100,
1321      101,   102,   103,   104,   105,    62,    63,    64,    65,    66,
1322       67
1323 };
1324
1325 /* YYSTOS[STATE-NUM] -- The (internal number of the) accessing
1326    symbol of state STATE-NUM.  */
1327 static const yytype_uint8 yystos[] =
1328 {
1329        0,   113,     0,    54,    70,    91,    92,    93,    94,    97,
1330      106,   110,   114,   120,   121,   122,   162,   163,   164,   165,
1331      170,   173,   178,   182,   183,   185,   191,   192,   200,   212,
1332      213,    94,   102,   106,   110,   209,   210,   194,   210,   210,
1333        5,    12,    13,    14,    15,    41,    42,    43,    44,    45,
1334       46,    48,    49,    50,    51,    52,    57,    58,    68,    69,
1335       71,   181,   191,    98,    99,   100,   101,   102,   103,   104,
1336      105,   210,   210,   210,   108,   208,    98,    99,   100,   101,
1337      102,   103,   104,   105,     3,    54,    55,    56,    83,    84,
1338       85,    86,    87,    88,    89,   197,   111,   194,   196,   195,
1339      196,   196,   195,   195,   194,   194,   194,   196,   186,   194,
1340      210,   210,   210,   210,   210,   210,   210,   210,   111,   209,
1341      210,   210,   210,   210,   210,   210,   210,   210,   179,   209,
1342      209,   209,     3,    92,    93,   197,   198,   197,   198,    16,
1343      126,   126,   198,   198,   209,     3,     3,   198,     3,    72,
1344       73,    74,    75,    76,    77,    78,     3,   198,   180,   208,
1345      115,   109,   212,   212,   208,   166,   171,   187,   209,   209,
1346      209,   209,   209,   209,   209,   174,   175,     1,     4,   209,
1347        4,    92,   116,   117,   212,   209,   208,   208,     3,     4,
1348       59,    61,   167,     4,    59,    61,   172,     4,    79,    80,
1349      207,   208,   207,     4,    95,    96,   176,   177,   203,   204,
1350      210,   108,   201,   202,   203,   204,   108,   211,   208,   208,
1351      184,    60,   199,   200,   199,    60,   199,   199,     3,     3,
1352      207,   207,   108,    96,    95,   202,   201,   212,   108,   208,
1353      208,     4,    53,    60,   200,   208,   168,   208,     3,   208,
1354      188,    81,   207,   207,   203,   204,   210,     6,     7,     8,
1355        9,    10,    11,   118,   119,   123,   124,   208,   191,   168,
1356        3,    62,    63,    64,    65,    66,    67,   108,   169,   208,
1357      171,     3,   208,     4,    82,   199,   108,   119,   127,   127,
1358      125,   166,   169,   207,     4,   171,     3,   208,     3,   190,
1359      119,     3,    16,    17,    18,    19,    41,    54,    55,    56,
1360       57,     3,   127,     4,     4,   171,   207,   189,     4,   208,
1361      128,   209,   199,   191,   199,   200,    90,    94,   110,   205,
1362      206,   209,   209,   209,   209,   191,   128,     3,     4,     3,
1363        4,    81,   208,     4,    10,    20,    21,    22,    23,    24,
1364       25,    26,    27,    28,    29,    30,    31,    32,    33,    34,
1365       35,    36,    37,    38,    39,    40,    42,   129,   206,   209,
1366       98,   108,   208,     4,   128,   171,   199,   153,   154,   199,
1367      212,   153,   153,   153,   153,   135,   153,   153,   138,   153,
1368      142,   153,   153,   153,   153,   153,   148,   153,   192,   193,
1369      212,   153,   153,   153,   193,   111,    90,   206,   199,     4,
1370        4,   108,   209,   108,   130,   131,   132,   134,   151,   209,
1371      136,   137,   151,   139,   151,   143,   144,   145,   146,   147,
1372      151,   149,   108,   209,   108,   133,   140,   141,   209,   206,
1373      208,   199,   108,   152,   151,   151,   151,   151,   208,   151,
1374      151,   151,   151,   151,   151,   151,   151,   151,   108,   151,
1375      151,   151,   208,   208,   154,   108,   156,   208,   209,   208,
1376      208,   157,   208,   208,   108,     3,   155,   208,   205,   208,
1377      208,   209,   174,   208,   208,   108,   155,   160,   108,     4,
1378      108,   155,   158,   208,   161,   207,   208,   209,   159,   207,
1379      208,   207,   208,   205,   155,   208,   108,   205,   155,   208,
1380      155,   208,   155,   209,   155,   155,   108,   150,   205,   207
1381 };
1382
1383 #define yyerrok         (yyerrstatus = 0)
1384 #define yyclearin       (yychar = YYEMPTY)
1385 #define YYEMPTY         (-2)
1386 #define YYEOF           0
1387
1388 #define YYACCEPT        goto yyacceptlab
1389 #define YYABORT         goto yyabortlab
1390 #define YYERROR         goto yyerrorlab
1391
1392
1393 /* Like YYERROR except do call yyerror.  This remains here temporarily
1394    to ease the transition to the new meaning of YYERROR, for GCC.
1395    Once GCC version 2 has supplanted version 1, this can go.  */
1396
1397 #define YYFAIL          goto yyerrlab
1398
1399 #define YYRECOVERING()  (!!yyerrstatus)
1400
1401 #define YYBACKUP(Token, Value)                                  \
1402 do                                                              \
1403   if (yychar == YYEMPTY && yylen == 1)                          \
1404     {                                                           \
1405       yychar = (Token);                                         \
1406       yylval = (Value);                                         \
1407       yytoken = YYTRANSLATE (yychar);                           \
1408       YYPOPSTACK (1);                                           \
1409       goto yybackup;                                            \
1410     }                                                           \
1411   else                                                          \
1412     {                                                           \
1413       yyerror (YY_("syntax error: cannot back up")); \
1414       YYERROR;                                                  \
1415     }                                                           \
1416 while (YYID (0))
1417
1418
1419 #define YYTERROR        1
1420 #define YYERRCODE       256
1421
1422
1423 /* YYLLOC_DEFAULT -- Set CURRENT to span from RHS[1] to RHS[N].
1424    If N is 0, then set CURRENT to the empty location which ends
1425    the previous symbol: RHS[0] (always defined).  */
1426
1427 #define YYRHSLOC(Rhs, K) ((Rhs)[K])
1428 #ifndef YYLLOC_DEFAULT
1429 # define YYLLOC_DEFAULT(Current, Rhs, N)                                \
1430     do                                                                  \
1431       if (YYID (N))                                                    \
1432         {                                                               \
1433           (Current).first_line   = YYRHSLOC (Rhs, 1).first_line;        \
1434           (Current).first_column = YYRHSLOC (Rhs, 1).first_column;      \
1435           (Current).last_line    = YYRHSLOC (Rhs, N).last_line;         \
1436           (Current).last_column  = YYRHSLOC (Rhs, N).last_column;       \
1437         }                                                               \
1438       else                                                              \
1439         {                                                               \
1440           (Current).first_line   = (Current).last_line   =              \
1441             YYRHSLOC (Rhs, 0).last_line;                                \
1442           (Current).first_column = (Current).last_column =              \
1443             YYRHSLOC (Rhs, 0).last_column;                              \
1444         }                                                               \
1445     while (YYID (0))
1446 #endif
1447
1448
1449 /* YY_LOCATION_PRINT -- Print the location on the stream.
1450    This macro was not mandated originally: define only if we know
1451    we won't break user code: when these are the locations we know.  */
1452
1453 #ifndef YY_LOCATION_PRINT
1454 # if defined YYLTYPE_IS_TRIVIAL && YYLTYPE_IS_TRIVIAL
1455 #  define YY_LOCATION_PRINT(File, Loc)                  \
1456      fprintf (File, "%d.%d-%d.%d",                      \
1457               (Loc).first_line, (Loc).first_column,     \
1458               (Loc).last_line,  (Loc).last_column)
1459 # else
1460 #  define YY_LOCATION_PRINT(File, Loc) ((void) 0)
1461 # endif
1462 #endif
1463
1464
1465 /* YYLEX -- calling `yylex' with the right arguments.  */
1466
1467 #ifdef YYLEX_PARAM
1468 # define YYLEX yylex (YYLEX_PARAM)
1469 #else
1470 # define YYLEX yylex ()
1471 #endif
1472
1473 /* Enable debugging if requested.  */
1474 #if YYDEBUG
1475
1476 # ifndef YYFPRINTF
1477 #  include <stdio.h> /* INFRINGES ON USER NAME SPACE */
1478 #  define YYFPRINTF fprintf
1479 # endif
1480
1481 # define YYDPRINTF(Args)                        \
1482 do {                                            \
1483   if (yydebug)                                  \
1484     YYFPRINTF Args;                             \
1485 } while (YYID (0))
1486
1487 # define YY_SYMBOL_PRINT(Title, Type, Value, Location)                    \
1488 do {                                                                      \
1489   if (yydebug)                                                            \
1490     {                                                                     \
1491       YYFPRINTF (stderr, "%s ", Title);                                   \
1492       yy_symbol_print (stderr,                                            \
1493                   Type, Value); \
1494       YYFPRINTF (stderr, "\n");                                           \
1495     }                                                                     \
1496 } while (YYID (0))
1497
1498
1499 /*--------------------------------.
1500 | Print this symbol on YYOUTPUT.  |
1501 `--------------------------------*/
1502
1503 /*ARGSUSED*/
1504 #if (defined __STDC__ || defined __C99__FUNC__ \
1505      || defined __cplusplus || defined _MSC_VER)
1506 static void
1507 yy_symbol_value_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep)
1508 #else
1509 static void
1510 yy_symbol_value_print (yyoutput, yytype, yyvaluep)
1511     FILE *yyoutput;
1512     int yytype;
1513     YYSTYPE const * const yyvaluep;
1514 #endif
1515 {
1516   if (!yyvaluep)
1517     return;
1518 # ifdef YYPRINT
1519   if (yytype < YYNTOKENS)
1520     YYPRINT (yyoutput, yytoknum[yytype], *yyvaluep);
1521 # else
1522   YYUSE (yyoutput);
1523 # endif
1524   switch (yytype)
1525     {
1526       default:
1527         break;
1528     }
1529 }
1530
1531
1532 /*--------------------------------.
1533 | Print this symbol on YYOUTPUT.  |
1534 `--------------------------------*/
1535
1536 #if (defined __STDC__ || defined __C99__FUNC__ \
1537      || defined __cplusplus || defined _MSC_VER)
1538 static void
1539 yy_symbol_print (FILE *yyoutput, int yytype, YYSTYPE const * const yyvaluep)
1540 #else
1541 static void
1542 yy_symbol_print (yyoutput, yytype, yyvaluep)
1543     FILE *yyoutput;
1544     int yytype;
1545     YYSTYPE const * const yyvaluep;
1546 #endif
1547 {
1548   if (yytype < YYNTOKENS)
1549     YYFPRINTF (yyoutput, "token %s (", yytname[yytype]);
1550   else
1551     YYFPRINTF (yyoutput, "nterm %s (", yytname[yytype]);
1552
1553   yy_symbol_value_print (yyoutput, yytype, yyvaluep);
1554   YYFPRINTF (yyoutput, ")");
1555 }
1556
1557 /*------------------------------------------------------------------.
1558 | yy_stack_print -- Print the state stack from its BOTTOM up to its |
1559 | TOP (included).                                                   |
1560 `------------------------------------------------------------------*/
1561
1562 #if (defined __STDC__ || defined __C99__FUNC__ \
1563      || defined __cplusplus || defined _MSC_VER)
1564 static void
1565 yy_stack_print (yytype_int16 *bottom, yytype_int16 *top)
1566 #else
1567 static void
1568 yy_stack_print (bottom, top)
1569     yytype_int16 *bottom;
1570     yytype_int16 *top;
1571 #endif
1572 {
1573   YYFPRINTF (stderr, "Stack now");
1574   for (; bottom <= top; ++bottom)
1575     YYFPRINTF (stderr, " %d", *bottom);
1576   YYFPRINTF (stderr, "\n");
1577 }
1578
1579 # define YY_STACK_PRINT(Bottom, Top)                            \
1580 do {                                                            \
1581   if (yydebug)                                                  \
1582     yy_stack_print ((Bottom), (Top));                           \
1583 } while (YYID (0))
1584
1585
1586 /*------------------------------------------------.
1587 | Report that the YYRULE is going to be reduced.  |
1588 `------------------------------------------------*/
1589
1590 #if (defined __STDC__ || defined __C99__FUNC__ \
1591      || defined __cplusplus || defined _MSC_VER)
1592 static void
1593 yy_reduce_print (YYSTYPE *yyvsp, int yyrule)
1594 #else
1595 static void
1596 yy_reduce_print (yyvsp, yyrule)
1597     YYSTYPE *yyvsp;
1598     int yyrule;
1599 #endif
1600 {
1601   int yynrhs = yyr2[yyrule];
1602   int yyi;
1603   unsigned long int yylno = yyrline[yyrule];
1604   YYFPRINTF (stderr, "Reducing stack by rule %d (line %lu):\n",
1605              yyrule - 1, yylno);
1606   /* The symbols being reduced.  */
1607   for (yyi = 0; yyi < yynrhs; yyi++)
1608     {
1609       fprintf (stderr, "   $%d = ", yyi + 1);
1610       yy_symbol_print (stderr, yyrhs[yyprhs[yyrule] + yyi],
1611                        &(yyvsp[(yyi + 1) - (yynrhs)])
1612                                        );
1613       fprintf (stderr, "\n");
1614     }
1615 }
1616
1617 # define YY_REDUCE_PRINT(Rule)          \
1618 do {                                    \
1619   if (yydebug)                          \
1620     yy_reduce_print (yyvsp, Rule); \
1621 } while (YYID (0))
1622
1623 /* Nonzero means print parse trace.  It is left uninitialized so that
1624    multiple parsers can coexist.  */
1625 int yydebug;
1626 #else /* !YYDEBUG */
1627 # define YYDPRINTF(Args)
1628 # define YY_SYMBOL_PRINT(Title, Type, Value, Location)
1629 # define YY_STACK_PRINT(Bottom, Top)
1630 # define YY_REDUCE_PRINT(Rule)
1631 #endif /* !YYDEBUG */
1632
1633
1634 /* YYINITDEPTH -- initial size of the parser's stacks.  */
1635 #ifndef YYINITDEPTH
1636 # define YYINITDEPTH 200
1637 #endif
1638
1639 /* YYMAXDEPTH -- maximum size the stacks can grow to (effective only
1640    if the built-in stack extension method is used).
1641
1642    Do not make this value too large; the results are undefined if
1643    YYSTACK_ALLOC_MAXIMUM < YYSTACK_BYTES (YYMAXDEPTH)
1644    evaluated with infinite-precision integer arithmetic.  */
1645
1646 #ifndef YYMAXDEPTH
1647 # define YYMAXDEPTH 10000
1648 #endif
1649
1650 \f
1651
1652 #if YYERROR_VERBOSE
1653
1654 # ifndef yystrlen
1655 #  if defined __GLIBC__ && defined _STRING_H
1656 #   define yystrlen strlen
1657 #  else
1658 /* Return the length of YYSTR.  */
1659 #if (defined __STDC__ || defined __C99__FUNC__ \
1660      || defined __cplusplus || defined _MSC_VER)
1661 static YYSIZE_T
1662 yystrlen (const char *yystr)
1663 #else
1664 static YYSIZE_T
1665 yystrlen (yystr)
1666     const char *yystr;
1667 #endif
1668 {
1669   YYSIZE_T yylen;
1670   for (yylen = 0; yystr[yylen]; yylen++)
1671     continue;
1672   return yylen;
1673 }
1674 #  endif
1675 # endif
1676
1677 # ifndef yystpcpy
1678 #  if defined __GLIBC__ && defined _STRING_H && defined _GNU_SOURCE
1679 #   define yystpcpy stpcpy
1680 #  else
1681 /* Copy YYSRC to YYDEST, returning the address of the terminating '\0' in
1682    YYDEST.  */
1683 #if (defined __STDC__ || defined __C99__FUNC__ \
1684      || defined __cplusplus || defined _MSC_VER)
1685 static char *
1686 yystpcpy (char *yydest, const char *yysrc)
1687 #else
1688 static char *
1689 yystpcpy (yydest, yysrc)
1690     char *yydest;
1691     const char *yysrc;
1692 #endif
1693 {
1694   char *yyd = yydest;
1695   const char *yys = yysrc;
1696
1697   while ((*yyd++ = *yys++) != '\0')
1698     continue;
1699
1700   return yyd - 1;
1701 }
1702 #  endif
1703 # endif
1704
1705 # ifndef yytnamerr
1706 /* Copy to YYRES the contents of YYSTR after stripping away unnecessary
1707    quotes and backslashes, so that it's suitable for yyerror.  The
1708    heuristic is that double-quoting is unnecessary unless the string
1709    contains an apostrophe, a comma, or backslash (other than
1710    backslash-backslash).  YYSTR is taken from yytname.  If YYRES is
1711    null, do not copy; instead, return the length of what the result
1712    would have been.  */
1713 static YYSIZE_T
1714 yytnamerr (char *yyres, const char *yystr)
1715 {
1716   if (*yystr == '"')
1717     {
1718       YYSIZE_T yyn = 0;
1719       char const *yyp = yystr;
1720
1721       for (;;)
1722         switch (*++yyp)
1723           {
1724           case '\'':
1725           case ',':
1726             goto do_not_strip_quotes;
1727
1728           case '\\':
1729             if (*++yyp != '\\')
1730               goto do_not_strip_quotes;
1731             /* Fall through.  */
1732           default:
1733             if (yyres)
1734               yyres[yyn] = *yyp;
1735             yyn++;
1736             break;
1737
1738           case '"':
1739             if (yyres)
1740               yyres[yyn] = '\0';
1741             return yyn;
1742           }
1743     do_not_strip_quotes: ;
1744     }
1745
1746   if (! yyres)
1747     return yystrlen (yystr);
1748
1749   return yystpcpy (yyres, yystr) - yyres;
1750 }
1751 # endif
1752
1753 /* Copy into YYRESULT an error message about the unexpected token
1754    YYCHAR while in state YYSTATE.  Return the number of bytes copied,
1755    including the terminating null byte.  If YYRESULT is null, do not
1756    copy anything; just return the number of bytes that would be
1757    copied.  As a special case, return 0 if an ordinary "syntax error"
1758    message will do.  Return YYSIZE_MAXIMUM if overflow occurs during
1759    size calculation.  */
1760 static YYSIZE_T
1761 yysyntax_error (char *yyresult, int yystate, int yychar)
1762 {
1763   int yyn = yypact[yystate];
1764
1765   if (! (YYPACT_NINF < yyn && yyn <= YYLAST))
1766     return 0;
1767   else
1768     {
1769       int yytype = YYTRANSLATE (yychar);
1770       YYSIZE_T yysize0 = yytnamerr (0, yytname[yytype]);
1771       YYSIZE_T yysize = yysize0;
1772       YYSIZE_T yysize1;
1773       int yysize_overflow = 0;
1774       enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 };
1775       char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM];
1776       int yyx;
1777
1778 # if 0
1779       /* This is so xgettext sees the translatable formats that are
1780          constructed on the fly.  */
1781       YY_("syntax error, unexpected %s");
1782       YY_("syntax error, unexpected %s, expecting %s");
1783       YY_("syntax error, unexpected %s, expecting %s or %s");
1784       YY_("syntax error, unexpected %s, expecting %s or %s or %s");
1785       YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s");
1786 # endif
1787       char *yyfmt;
1788       char const *yyf;
1789       static char const yyunexpected[] = "syntax error, unexpected %s";
1790       static char const yyexpecting[] = ", expecting %s";
1791       static char const yyor[] = " or %s";
1792       char yyformat[sizeof yyunexpected
1793                     + sizeof yyexpecting - 1
1794                     + ((YYERROR_VERBOSE_ARGS_MAXIMUM - 2)
1795                        * (sizeof yyor - 1))];
1796       char const *yyprefix = yyexpecting;
1797
1798       /* Start YYX at -YYN if negative to avoid negative indexes in
1799          YYCHECK.  */
1800       int yyxbegin = yyn < 0 ? -yyn : 0;
1801
1802       /* Stay within bounds of both yycheck and yytname.  */
1803       int yychecklim = YYLAST - yyn + 1;
1804       int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS;
1805       int yycount = 1;
1806
1807       yyarg[0] = yytname[yytype];
1808       yyfmt = yystpcpy (yyformat, yyunexpected);
1809
1810       for (yyx = yyxbegin; yyx < yyxend; ++yyx)
1811         if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR)
1812           {
1813             if (yycount == YYERROR_VERBOSE_ARGS_MAXIMUM)
1814               {
1815                 yycount = 1;
1816                 yysize = yysize0;
1817                 yyformat[sizeof yyunexpected - 1] = '\0';
1818                 break;
1819               }
1820             yyarg[yycount++] = yytname[yyx];
1821             yysize1 = yysize + yytnamerr (0, yytname[yyx]);
1822             yysize_overflow |= (yysize1 < yysize);
1823             yysize = yysize1;
1824             yyfmt = yystpcpy (yyfmt, yyprefix);
1825             yyprefix = yyor;
1826           }
1827
1828       yyf = YY_(yyformat);
1829       yysize1 = yysize + yystrlen (yyf);
1830       yysize_overflow |= (yysize1 < yysize);
1831       yysize = yysize1;
1832
1833       if (yysize_overflow)
1834         return YYSIZE_MAXIMUM;
1835
1836       if (yyresult)
1837         {
1838           /* Avoid sprintf, as that infringes on the user's name space.
1839              Don't have undefined behavior even if the translation
1840              produced a string with the wrong number of "%s"s.  */
1841           char *yyp = yyresult;
1842           int yyi = 0;
1843           while ((*yyp = *yyf) != '\0')
1844             {
1845               if (*yyp == '%' && yyf[1] == 's' && yyi < yycount)
1846                 {
1847                   yyp += yytnamerr (yyp, yyarg[yyi++]);
1848                   yyf += 2;
1849                 }
1850               else
1851                 {
1852                   yyp++;
1853                   yyf++;
1854                 }
1855             }
1856         }
1857       return yysize;
1858     }
1859 }
1860 #endif /* YYERROR_VERBOSE */
1861 \f
1862
1863 /*-----------------------------------------------.
1864 | Release the memory associated to this symbol.  |
1865 `-----------------------------------------------*/
1866
1867 /*ARGSUSED*/
1868 #if (defined __STDC__ || defined __C99__FUNC__ \
1869      || defined __cplusplus || defined _MSC_VER)
1870 static void
1871 yydestruct (const char *yymsg, int yytype, YYSTYPE *yyvaluep)
1872 #else
1873 static void
1874 yydestruct (yymsg, yytype, yyvaluep)
1875     const char *yymsg;
1876     int yytype;
1877     YYSTYPE *yyvaluep;
1878 #endif
1879 {
1880   YYUSE (yyvaluep);
1881
1882   if (!yymsg)
1883     yymsg = "Deleting";
1884   YY_SYMBOL_PRINT (yymsg, yytype, yyvaluep, yylocationp);
1885
1886   switch (yytype)
1887     {
1888
1889       default:
1890         break;
1891     }
1892 }
1893 \f
1894
1895 /* Prevent warnings from -Wmissing-prototypes.  */
1896
1897 #ifdef YYPARSE_PARAM
1898 #if defined __STDC__ || defined __cplusplus
1899 int yyparse (void *YYPARSE_PARAM);
1900 #else
1901 int yyparse ();
1902 #endif
1903 #else /* ! YYPARSE_PARAM */
1904 #if defined __STDC__ || defined __cplusplus
1905 int yyparse (void);
1906 #else
1907 int yyparse ();
1908 #endif
1909 #endif /* ! YYPARSE_PARAM */
1910
1911
1912
1913 /* The look-ahead symbol.  */
1914 int yychar;
1915
1916 /* The semantic value of the look-ahead symbol.  */
1917 YYSTYPE yylval;
1918
1919 /* Number of syntax errors so far.  */
1920 int yynerrs;
1921
1922
1923
1924 /*----------.
1925 | yyparse.  |
1926 `----------*/
1927
1928 #ifdef YYPARSE_PARAM
1929 #if (defined __STDC__ || defined __C99__FUNC__ \
1930      || defined __cplusplus || defined _MSC_VER)
1931 int
1932 yyparse (void *YYPARSE_PARAM)
1933 #else
1934 int
1935 yyparse (YYPARSE_PARAM)
1936     void *YYPARSE_PARAM;
1937 #endif
1938 #else /* ! YYPARSE_PARAM */
1939 #if (defined __STDC__ || defined __C99__FUNC__ \
1940      || defined __cplusplus || defined _MSC_VER)
1941 int
1942 yyparse (void)
1943 #else
1944 int
1945 yyparse ()
1946
1947 #endif
1948 #endif
1949 {
1950   
1951   int yystate;
1952   int yyn;
1953   int yyresult;
1954   /* Number of tokens to shift before error messages enabled.  */
1955   int yyerrstatus;
1956   /* Look-ahead token as an internal (translated) token number.  */
1957   int yytoken = 0;
1958 #if YYERROR_VERBOSE
1959   /* Buffer for error messages, and its allocated size.  */
1960   char yymsgbuf[128];
1961   char *yymsg = yymsgbuf;
1962   YYSIZE_T yymsg_alloc = sizeof yymsgbuf;
1963 #endif
1964
1965   /* Three stacks and their tools:
1966      `yyss': related to states,
1967      `yyvs': related to semantic values,
1968      `yyls': related to locations.
1969
1970      Refer to the stacks thru separate pointers, to allow yyoverflow
1971      to reallocate them elsewhere.  */
1972
1973   /* The state stack.  */
1974   yytype_int16 yyssa[YYINITDEPTH];
1975   yytype_int16 *yyss = yyssa;
1976   yytype_int16 *yyssp;
1977
1978   /* The semantic value stack.  */
1979   YYSTYPE yyvsa[YYINITDEPTH];
1980   YYSTYPE *yyvs = yyvsa;
1981   YYSTYPE *yyvsp;
1982
1983
1984
1985 #define YYPOPSTACK(N)   (yyvsp -= (N), yyssp -= (N))
1986
1987   YYSIZE_T yystacksize = YYINITDEPTH;
1988
1989   /* The variables used to return semantic value and location from the
1990      action routines.  */
1991   YYSTYPE yyval;
1992
1993
1994   /* The number of symbols on the RHS of the reduced rule.
1995      Keep to zero when no symbol should be popped.  */
1996   int yylen = 0;
1997
1998   YYDPRINTF ((stderr, "Starting parse\n"));
1999
2000   yystate = 0;
2001   yyerrstatus = 0;
2002   yynerrs = 0;
2003   yychar = YYEMPTY;             /* Cause a token to be read.  */
2004
2005   /* Initialize stack pointers.
2006      Waste one element of value and location stack
2007      so that they stay on the same level as the state stack.
2008      The wasted elements are never initialized.  */
2009
2010   yyssp = yyss;
2011   yyvsp = yyvs;
2012
2013   goto yysetstate;
2014
2015 /*------------------------------------------------------------.
2016 | yynewstate -- Push a new state, which is found in yystate.  |
2017 `------------------------------------------------------------*/
2018  yynewstate:
2019   /* In all cases, when you get here, the value and location stacks
2020      have just been pushed.  So pushing a state here evens the stacks.  */
2021   yyssp++;
2022
2023  yysetstate:
2024   *yyssp = yystate;
2025
2026   if (yyss + yystacksize - 1 <= yyssp)
2027     {
2028       /* Get the current used size of the three stacks, in elements.  */
2029       YYSIZE_T yysize = yyssp - yyss + 1;
2030
2031 #ifdef yyoverflow
2032       {
2033         /* Give user a chance to reallocate the stack.  Use copies of
2034            these so that the &'s don't force the real ones into
2035            memory.  */
2036         YYSTYPE *yyvs1 = yyvs;
2037         yytype_int16 *yyss1 = yyss;
2038
2039
2040         /* Each stack pointer address is followed by the size of the
2041            data in use in that stack, in bytes.  This used to be a
2042            conditional around just the two extra args, but that might
2043            be undefined if yyoverflow is a macro.  */
2044         yyoverflow (YY_("memory exhausted"),
2045                     &yyss1, yysize * sizeof (*yyssp),
2046                     &yyvs1, yysize * sizeof (*yyvsp),
2047
2048                     &yystacksize);
2049
2050         yyss = yyss1;
2051         yyvs = yyvs1;
2052       }
2053 #else /* no yyoverflow */
2054 # ifndef YYSTACK_RELOCATE
2055       goto yyexhaustedlab;
2056 # else
2057       /* Extend the stack our own way.  */
2058       if (YYMAXDEPTH <= yystacksize)
2059         goto yyexhaustedlab;
2060       yystacksize *= 2;
2061       if (YYMAXDEPTH < yystacksize)
2062         yystacksize = YYMAXDEPTH;
2063
2064       {
2065         yytype_int16 *yyss1 = yyss;
2066         union yyalloc *yyptr =
2067           (union yyalloc *) YYSTACK_ALLOC (YYSTACK_BYTES (yystacksize));
2068         if (! yyptr)
2069           goto yyexhaustedlab;
2070         YYSTACK_RELOCATE (yyss);
2071         YYSTACK_RELOCATE (yyvs);
2072
2073 #  undef YYSTACK_RELOCATE
2074         if (yyss1 != yyssa)
2075           YYSTACK_FREE (yyss1);
2076       }
2077 # endif
2078 #endif /* no yyoverflow */
2079
2080       yyssp = yyss + yysize - 1;
2081       yyvsp = yyvs + yysize - 1;
2082
2083
2084       YYDPRINTF ((stderr, "Stack size increased to %lu\n",
2085                   (unsigned long int) yystacksize));
2086
2087       if (yyss + yystacksize - 1 <= yyssp)
2088         YYABORT;
2089     }
2090
2091   YYDPRINTF ((stderr, "Entering state %d\n", yystate));
2092
2093   goto yybackup;
2094
2095 /*-----------.
2096 | yybackup.  |
2097 `-----------*/
2098 yybackup:
2099
2100   /* Do appropriate processing given the current state.  Read a
2101      look-ahead token if we need one and don't already have one.  */
2102
2103   /* First try to decide what to do without reference to look-ahead token.  */
2104   yyn = yypact[yystate];
2105   if (yyn == YYPACT_NINF)
2106     goto yydefault;
2107
2108   /* Not known => get a look-ahead token if don't already have one.  */
2109
2110   /* YYCHAR is either YYEMPTY or YYEOF or a valid look-ahead symbol.  */
2111   if (yychar == YYEMPTY)
2112     {
2113       YYDPRINTF ((stderr, "Reading a token: "));
2114       yychar = YYLEX;
2115     }
2116
2117   if (yychar <= YYEOF)
2118     {
2119       yychar = yytoken = YYEOF;
2120       YYDPRINTF ((stderr, "Now at end of input.\n"));
2121     }
2122   else
2123     {
2124       yytoken = YYTRANSLATE (yychar);
2125       YY_SYMBOL_PRINT ("Next token is", yytoken, &yylval, &yylloc);
2126     }
2127
2128   /* If the proper action on seeing token YYTOKEN is to reduce or to
2129      detect an error, take that action.  */
2130   yyn += yytoken;
2131   if (yyn < 0 || YYLAST < yyn || yycheck[yyn] != yytoken)
2132     goto yydefault;
2133   yyn = yytable[yyn];
2134   if (yyn <= 0)
2135     {
2136       if (yyn == 0 || yyn == YYTABLE_NINF)
2137         goto yyerrlab;
2138       yyn = -yyn;
2139       goto yyreduce;
2140     }
2141
2142   if (yyn == YYFINAL)
2143     YYACCEPT;
2144
2145   /* Count tokens shifted since error; after three, turn off error
2146      status.  */
2147   if (yyerrstatus)
2148     yyerrstatus--;
2149
2150   /* Shift the look-ahead token.  */
2151   YY_SYMBOL_PRINT ("Shifting", yytoken, &yylval, &yylloc);
2152
2153   /* Discard the shifted token unless it is eof.  */
2154   if (yychar != YYEOF)
2155     yychar = YYEMPTY;
2156
2157   yystate = yyn;
2158   *++yyvsp = yylval;
2159
2160   goto yynewstate;
2161
2162
2163 /*-----------------------------------------------------------.
2164 | yydefault -- do the default action for the current state.  |
2165 `-----------------------------------------------------------*/
2166 yydefault:
2167   yyn = yydefact[yystate];
2168   if (yyn == 0)
2169     goto yyerrlab;
2170   goto yyreduce;
2171
2172
2173 /*-----------------------------.
2174 | yyreduce -- Do a reduction.  |
2175 `-----------------------------*/
2176 yyreduce:
2177   /* yyn is the number of a rule to reduce with.  */
2178   yylen = yyr2[yyn];
2179
2180   /* If YYLEN is nonzero, implement the default value of the action:
2181      `$$ = $1'.
2182
2183      Otherwise, the following line sets YYVAL to garbage.
2184      This behavior is undocumented and Bison
2185      users should not rely upon it.  Assigning to YYVAL
2186      unconditionally makes the parser a bit smaller, and it avoids a
2187      GCC warning that YYVAL may be used uninitialized.  */
2188   yyval = yyvsp[1-yylen];
2189
2190
2191   YY_REDUCE_PRINT (yyn);
2192   switch (yyn)
2193     {
2194         case 18:
2195 #line 201 "rcparse.y"
2196     {
2197             define_accelerator ((yyvsp[(1) - (6)].id), &(yyvsp[(3) - (6)].res_info), (yyvsp[(5) - (6)].pacc));
2198             if (yychar != YYEMPTY)
2199               YYERROR;
2200             rcparse_discard_strings ();
2201           }
2202     break;
2203
2204   case 19:
2205 #line 211 "rcparse.y"
2206     {
2207             (yyval.pacc) = NULL;
2208           }
2209     break;
2210
2211   case 20:
2212 #line 215 "rcparse.y"
2213     {
2214             rc_accelerator *a;
2215
2216             a = (rc_accelerator *) res_alloc (sizeof *a);
2217             *a = (yyvsp[(2) - (2)].acc);
2218             if ((yyvsp[(1) - (2)].pacc) == NULL)
2219               (yyval.pacc) = a;
2220             else
2221               {
2222                 rc_accelerator **pp;
2223
2224                 for (pp = &(yyvsp[(1) - (2)].pacc)->next; *pp != NULL; pp = &(*pp)->next)
2225                   ;
2226                 *pp = a;
2227                 (yyval.pacc) = (yyvsp[(1) - (2)].pacc);
2228               }
2229           }
2230     break;
2231
2232   case 21:
2233 #line 236 "rcparse.y"
2234     {
2235             (yyval.acc) = (yyvsp[(1) - (2)].acc);
2236             (yyval.acc).id = (yyvsp[(2) - (2)].il);
2237           }
2238     break;
2239
2240   case 22:
2241 #line 241 "rcparse.y"
2242     {
2243             (yyval.acc) = (yyvsp[(1) - (4)].acc);
2244             (yyval.acc).id = (yyvsp[(2) - (4)].il);
2245             (yyval.acc).flags |= (yyvsp[(4) - (4)].is);
2246             if (((yyval.acc).flags & ACC_VIRTKEY) == 0
2247                 && ((yyval.acc).flags & (ACC_SHIFT | ACC_CONTROL)) != 0)
2248               rcparse_warning (_("inappropriate modifiers for non-VIRTKEY"));
2249           }
2250     break;
2251
2252   case 23:
2253 #line 253 "rcparse.y"
2254     {
2255             const char *s = (yyvsp[(1) - (1)].s);
2256             char ch;
2257
2258             (yyval.acc).next = NULL;
2259             (yyval.acc).id = 0;
2260             ch = *s;
2261             if (ch != '^')
2262               (yyval.acc).flags = 0;
2263             else
2264               {
2265                 (yyval.acc).flags = ACC_CONTROL | ACC_VIRTKEY;
2266                 ++s;
2267                 ch = TOUPPER (s[0]);
2268               }
2269             (yyval.acc).key = ch;
2270             if (s[1] != '\0')
2271               rcparse_warning (_("accelerator should only be one character"));
2272           }
2273     break;
2274
2275   case 24:
2276 #line 273 "rcparse.y"
2277     {
2278             (yyval.acc).next = NULL;
2279             (yyval.acc).flags = 0;
2280             (yyval.acc).id = 0;
2281             (yyval.acc).key = (yyvsp[(1) - (1)].il);
2282           }
2283     break;
2284
2285   case 25:
2286 #line 283 "rcparse.y"
2287     {
2288             (yyval.is) = (yyvsp[(1) - (1)].is);
2289           }
2290     break;
2291
2292   case 26:
2293 #line 287 "rcparse.y"
2294     {
2295             (yyval.is) = (yyvsp[(1) - (3)].is) | (yyvsp[(3) - (3)].is);
2296           }
2297     break;
2298
2299   case 27:
2300 #line 292 "rcparse.y"
2301     {
2302             (yyval.is) = (yyvsp[(1) - (2)].is) | (yyvsp[(2) - (2)].is);
2303           }
2304     break;
2305
2306   case 28:
2307 #line 299 "rcparse.y"
2308     {
2309             (yyval.is) = ACC_VIRTKEY;
2310           }
2311     break;
2312
2313   case 29:
2314 #line 303 "rcparse.y"
2315     {
2316             /* This is just the absence of VIRTKEY.  */
2317             (yyval.is) = 0;
2318           }
2319     break;
2320
2321   case 30:
2322 #line 308 "rcparse.y"
2323     {
2324             (yyval.is) = ACC_NOINVERT;
2325           }
2326     break;
2327
2328   case 31:
2329 #line 312 "rcparse.y"
2330     {
2331             (yyval.is) = ACC_SHIFT;
2332           }
2333     break;
2334
2335   case 32:
2336 #line 316 "rcparse.y"
2337     {
2338             (yyval.is) = ACC_CONTROL;
2339           }
2340     break;
2341
2342   case 33:
2343 #line 320 "rcparse.y"
2344     {
2345             (yyval.is) = ACC_ALT;
2346           }
2347     break;
2348
2349   case 34:
2350 #line 329 "rcparse.y"
2351     {
2352             define_bitmap ((yyvsp[(1) - (4)].id), &(yyvsp[(3) - (4)].res_info), (yyvsp[(4) - (4)].s));
2353             if (yychar != YYEMPTY)
2354               YYERROR;
2355             rcparse_discard_strings ();
2356           }
2357     break;
2358
2359   case 35:
2360 #line 341 "rcparse.y"
2361     {
2362             define_cursor ((yyvsp[(1) - (4)].id), &(yyvsp[(3) - (4)].res_info), (yyvsp[(4) - (4)].s));
2363             if (yychar != YYEMPTY)
2364               YYERROR;
2365             rcparse_discard_strings ();
2366           }
2367     break;
2368
2369   case 36:
2370 #line 354 "rcparse.y"
2371     {
2372               memset (&dialog, 0, sizeof dialog);
2373               dialog.x = (yyvsp[(5) - (8)].il);
2374               dialog.y = (yyvsp[(6) - (8)].il);
2375               dialog.width = (yyvsp[(7) - (8)].il);
2376               dialog.height = (yyvsp[(8) - (8)].il);
2377               dialog.style = WS_POPUP | WS_BORDER | WS_SYSMENU;
2378               dialog.exstyle = (yyvsp[(4) - (8)].il);
2379               dialog.menu.named = 1;
2380               dialog.class.named = 1;
2381               dialog.font = NULL;
2382               dialog.ex = NULL;
2383               dialog.controls = NULL;
2384               sub_res_info = (yyvsp[(3) - (8)].res_info);
2385               style = 0;
2386             }
2387     break;
2388
2389   case 37:
2390 #line 371 "rcparse.y"
2391     {
2392             define_dialog ((yyvsp[(1) - (13)].id), &sub_res_info, &dialog);
2393             if (yychar != YYEMPTY)
2394               YYERROR;
2395             rcparse_discard_strings ();
2396           }
2397     break;
2398
2399   case 38:
2400 #line 379 "rcparse.y"
2401     {
2402               memset (&dialog, 0, sizeof dialog);
2403               dialog.x = (yyvsp[(5) - (8)].il);
2404               dialog.y = (yyvsp[(6) - (8)].il);
2405               dialog.width = (yyvsp[(7) - (8)].il);
2406               dialog.height = (yyvsp[(8) - (8)].il);
2407               dialog.style = WS_POPUP | WS_BORDER | WS_SYSMENU;
2408               dialog.exstyle = (yyvsp[(4) - (8)].il);
2409               dialog.menu.named = 1;
2410               dialog.class.named = 1;
2411               dialog.font = NULL;
2412               dialog.ex = ((rc_dialog_ex *)
2413                            res_alloc (sizeof (rc_dialog_ex)));
2414               memset (dialog.ex, 0, sizeof (rc_dialog_ex));
2415               dialog.controls = NULL;
2416               sub_res_info = (yyvsp[(3) - (8)].res_info);
2417               style = 0;
2418             }
2419     break;
2420
2421   case 39:
2422 #line 398 "rcparse.y"
2423     {
2424             define_dialog ((yyvsp[(1) - (13)].id), &sub_res_info, &dialog);
2425             if (yychar != YYEMPTY)
2426               YYERROR;
2427             rcparse_discard_strings ();
2428           }
2429     break;
2430
2431   case 40:
2432 #line 406 "rcparse.y"
2433     {
2434               memset (&dialog, 0, sizeof dialog);
2435               dialog.x = (yyvsp[(5) - (9)].il);
2436               dialog.y = (yyvsp[(6) - (9)].il);
2437               dialog.width = (yyvsp[(7) - (9)].il);
2438               dialog.height = (yyvsp[(8) - (9)].il);
2439               dialog.style = WS_POPUP | WS_BORDER | WS_SYSMENU;
2440               dialog.exstyle = (yyvsp[(4) - (9)].il);
2441               dialog.menu.named = 1;
2442               dialog.class.named = 1;
2443               dialog.font = NULL;
2444               dialog.ex = ((rc_dialog_ex *)
2445                            res_alloc (sizeof (rc_dialog_ex)));
2446               memset (dialog.ex, 0, sizeof (rc_dialog_ex));
2447               dialog.ex->help = (yyvsp[(9) - (9)].il);
2448               dialog.controls = NULL;
2449               sub_res_info = (yyvsp[(3) - (9)].res_info);
2450               style = 0;
2451             }
2452     break;
2453
2454   case 41:
2455 #line 426 "rcparse.y"
2456     {
2457             define_dialog ((yyvsp[(1) - (14)].id), &sub_res_info, &dialog);
2458             if (yychar != YYEMPTY)
2459               YYERROR;
2460             rcparse_discard_strings ();
2461           }
2462     break;
2463
2464   case 42:
2465 #line 436 "rcparse.y"
2466     {
2467             (yyval.il) = 0;
2468           }
2469     break;
2470
2471   case 43:
2472 #line 440 "rcparse.y"
2473     {
2474             (yyval.il) = (yyvsp[(3) - (3)].il);
2475           }
2476     break;
2477
2478   case 45:
2479 #line 448 "rcparse.y"
2480     {
2481             dialog.style |= WS_CAPTION;
2482             style |= WS_CAPTION;
2483             dialog.caption = (yyvsp[(3) - (3)].uni);
2484           }
2485     break;
2486
2487   case 46:
2488 #line 454 "rcparse.y"
2489     {
2490             dialog.class = (yyvsp[(3) - (3)].id);
2491           }
2492     break;
2493
2494   case 47:
2495 #line 459 "rcparse.y"
2496     {
2497             dialog.style = style;
2498           }
2499     break;
2500
2501   case 48:
2502 #line 463 "rcparse.y"
2503     {
2504             dialog.exstyle = (yyvsp[(3) - (3)].il);
2505           }
2506     break;
2507
2508   case 49:
2509 #line 467 "rcparse.y"
2510     {
2511             res_unistring_to_id (& dialog.class, (yyvsp[(3) - (3)].uni));
2512           }
2513     break;
2514
2515   case 50:
2516 #line 471 "rcparse.y"
2517     {
2518             dialog.style |= DS_SETFONT;
2519             style |= DS_SETFONT;
2520             dialog.pointsize = (yyvsp[(3) - (5)].il);
2521             dialog.font = (yyvsp[(5) - (5)].uni);
2522             if (dialog.ex != NULL)
2523               {
2524                 dialog.ex->weight = 0;
2525                 dialog.ex->italic = 0;
2526                 dialog.ex->charset = 1;
2527               }
2528           }
2529     break;
2530
2531   case 51:
2532 #line 484 "rcparse.y"
2533     {
2534             dialog.style |= DS_SETFONT;
2535             style |= DS_SETFONT;
2536             dialog.pointsize = (yyvsp[(3) - (6)].il);
2537             dialog.font = (yyvsp[(5) - (6)].uni);
2538             if (dialog.ex == NULL)
2539               rcparse_warning (_("extended FONT requires DIALOGEX"));
2540             else
2541               {
2542                 dialog.ex->weight = (yyvsp[(6) - (6)].il);
2543                 dialog.ex->italic = 0;
2544                 dialog.ex->charset = 1;
2545               }
2546           }
2547     break;
2548
2549   case 52:
2550 #line 499 "rcparse.y"
2551     {
2552             dialog.style |= DS_SETFONT;
2553             style |= DS_SETFONT;
2554             dialog.pointsize = (yyvsp[(3) - (7)].il);
2555             dialog.font = (yyvsp[(5) - (7)].uni);
2556             if (dialog.ex == NULL)
2557               rcparse_warning (_("extended FONT requires DIALOGEX"));
2558             else
2559               {
2560                 dialog.ex->weight = (yyvsp[(6) - (7)].il);
2561                 dialog.ex->italic = (yyvsp[(7) - (7)].il);
2562                 dialog.ex->charset = 1;
2563               }
2564           }
2565     break;
2566
2567   case 53:
2568 #line 514 "rcparse.y"
2569     {
2570             dialog.style |= DS_SETFONT;
2571             style |= DS_SETFONT;
2572             dialog.pointsize = (yyvsp[(3) - (8)].il);
2573             dialog.font = (yyvsp[(5) - (8)].uni);
2574             if (dialog.ex == NULL)
2575               rcparse_warning (_("extended FONT requires DIALOGEX"));
2576             else
2577               {
2578                 dialog.ex->weight = (yyvsp[(6) - (8)].il);
2579                 dialog.ex->italic = (yyvsp[(7) - (8)].il);
2580                 dialog.ex->charset = (yyvsp[(8) - (8)].il);
2581               }
2582           }
2583     break;
2584
2585   case 54:
2586 #line 529 "rcparse.y"
2587     {
2588             dialog.menu = (yyvsp[(3) - (3)].id);
2589           }
2590     break;
2591
2592   case 55:
2593 #line 533 "rcparse.y"
2594     {
2595             sub_res_info.characteristics = (yyvsp[(3) - (3)].il);
2596           }
2597     break;
2598
2599   case 56:
2600 #line 537 "rcparse.y"
2601     {
2602             sub_res_info.language = (yyvsp[(3) - (4)].il) | ((yyvsp[(4) - (4)].il) << SUBLANG_SHIFT);
2603           }
2604     break;
2605
2606   case 57:
2607 #line 541 "rcparse.y"
2608     {
2609             sub_res_info.version = (yyvsp[(3) - (3)].il);
2610           }
2611     break;
2612
2613   case 59:
2614 #line 549 "rcparse.y"
2615     {
2616             rc_dialog_control **pp;
2617
2618             for (pp = &dialog.controls; *pp != NULL; pp = &(*pp)->next)
2619               ;
2620             *pp = (yyvsp[(2) - (2)].dialog_control);
2621           }
2622     break;
2623
2624   case 60:
2625 #line 560 "rcparse.y"
2626     {
2627               default_style = BS_AUTO3STATE | WS_TABSTOP;
2628               base_style = BS_AUTO3STATE;
2629               class.named = 0;
2630               class.u.id = CTL_BUTTON;
2631               res_text_field = (yyvsp[(2) - (2)].id);   
2632             }
2633     break;
2634
2635   case 61:
2636 #line 568 "rcparse.y"
2637     {
2638             (yyval.dialog_control) = (yyvsp[(4) - (4)].dialog_control);
2639           }
2640     break;
2641
2642   case 62:
2643 #line 572 "rcparse.y"
2644     {
2645               default_style = BS_AUTOCHECKBOX | WS_TABSTOP;
2646               base_style = BS_AUTOCHECKBOX;
2647               class.named = 0;
2648               class.u.id = CTL_BUTTON;
2649               res_text_field = (yyvsp[(2) - (2)].id);   
2650             }
2651     break;
2652
2653   case 63:
2654 #line 580 "rcparse.y"
2655     {
2656             (yyval.dialog_control) = (yyvsp[(4) - (4)].dialog_control);
2657           }
2658     break;
2659
2660   case 64:
2661 #line 584 "rcparse.y"
2662     {
2663               default_style = BS_AUTORADIOBUTTON | WS_TABSTOP;
2664               base_style = BS_AUTORADIOBUTTON;
2665               class.named = 0;
2666               class.u.id = CTL_BUTTON;
2667               res_text_field = (yyvsp[(2) - (2)].id);   
2668             }
2669     break;
2670
2671   case 65:
2672 #line 592 "rcparse.y"
2673     {
2674             (yyval.dialog_control) = (yyvsp[(4) - (4)].dialog_control);
2675           }
2676     break;
2677
2678   case 66:
2679 #line 596 "rcparse.y"
2680     {
2681               default_style = ES_LEFT | WS_BORDER | WS_TABSTOP;
2682               base_style = ES_LEFT | WS_BORDER | WS_TABSTOP;
2683               class.named = 0;
2684               class.u.id = CTL_EDIT;
2685               res_text_field = (yyvsp[(2) - (2)].id);   
2686             }
2687     break;
2688
2689   case 67:
2690 #line 604 "rcparse.y"
2691     {
2692             (yyval.dialog_control) = (yyvsp[(4) - (4)].dialog_control);
2693             if (dialog.ex == NULL)
2694               rcparse_warning (_("BEDIT requires DIALOGEX"));
2695             res_string_to_id (&(yyval.dialog_control)->class, "BEDIT");
2696           }
2697     break;
2698
2699   case 68:
2700 #line 611 "rcparse.y"
2701     {
2702               default_style = BS_CHECKBOX | WS_TABSTOP;
2703               base_style = BS_CHECKBOX | WS_TABSTOP;
2704               class.named = 0;
2705               class.u.id = CTL_BUTTON;
2706               res_text_field = (yyvsp[(2) - (2)].id);   
2707             }
2708     break;
2709
2710   case 69:
2711 #line 619 "rcparse.y"
2712     {
2713             (yyval.dialog_control) = (yyvsp[(4) - (4)].dialog_control);
2714           }
2715     break;
2716
2717   case 70:
2718 #line 623 "rcparse.y"
2719     {
2720               /* This is as per MSDN documentation.  With some (???)
2721                  versions of MS rc.exe their is no default style.  */
2722               default_style = CBS_SIMPLE | WS_TABSTOP;
2723               base_style = 0;
2724               class.named = 0;
2725               class.u.id = CTL_COMBOBOX;
2726               res_text_field = res_null_text;   
2727             }
2728     break;
2729
2730   case 71:
2731 #line 633 "rcparse.y"
2732     {
2733             (yyval.dialog_control) = (yyvsp[(3) - (3)].dialog_control);
2734           }
2735     break;
2736
2737   case 72:
2738 #line 638 "rcparse.y"
2739     {
2740             (yyval.dialog_control) = define_control ((yyvsp[(2) - (11)].id), (yyvsp[(3) - (11)].il), (yyvsp[(6) - (11)].il), (yyvsp[(7) - (11)].il), (yyvsp[(8) - (11)].il), (yyvsp[(9) - (11)].il), (yyvsp[(4) - (11)].id), style, (yyvsp[(10) - (11)].il));
2741             if ((yyvsp[(11) - (11)].rcdata_item) != NULL)
2742               {
2743                 if (dialog.ex == NULL)
2744                   rcparse_warning (_("control data requires DIALOGEX"));
2745                 (yyval.dialog_control)->data = (yyvsp[(11) - (11)].rcdata_item);
2746               }
2747           }
2748     break;
2749
2750   case 73:
2751 #line 649 "rcparse.y"
2752     {
2753             (yyval.dialog_control) = define_control ((yyvsp[(2) - (12)].id), (yyvsp[(3) - (12)].il), (yyvsp[(6) - (12)].il), (yyvsp[(7) - (12)].il), (yyvsp[(8) - (12)].il), (yyvsp[(9) - (12)].il), (yyvsp[(4) - (12)].id), style, (yyvsp[(10) - (12)].il));
2754             if (dialog.ex == NULL)
2755               rcparse_warning (_("help ID requires DIALOGEX"));
2756             (yyval.dialog_control)->help = (yyvsp[(11) - (12)].il);
2757             (yyval.dialog_control)->data = (yyvsp[(12) - (12)].rcdata_item);
2758           }
2759     break;
2760
2761   case 74:
2762 #line 657 "rcparse.y"
2763     {
2764               default_style = SS_CENTER | WS_GROUP;
2765               base_style = SS_CENTER;
2766               class.named = 0;
2767               class.u.id = CTL_STATIC;
2768               res_text_field = (yyvsp[(2) - (2)].id);   
2769             }
2770     break;
2771
2772   case 75:
2773 #line 665 "rcparse.y"
2774     {
2775             (yyval.dialog_control) = (yyvsp[(4) - (4)].dialog_control);
2776           }
2777     break;
2778
2779   case 76:
2780 #line 669 "rcparse.y"
2781     {
2782               default_style = BS_DEFPUSHBUTTON | WS_TABSTOP;
2783               base_style = BS_DEFPUSHBUTTON | WS_TABSTOP;
2784               class.named = 0;
2785               class.u.id = CTL_BUTTON;
2786               res_text_field = (yyvsp[(2) - (2)].id);   
2787             }
2788     break;
2789
2790   case 77:
2791 #line 677 "rcparse.y"
2792     {
2793             (yyval.dialog_control) = (yyvsp[(4) - (4)].dialog_control);
2794           }
2795     break;
2796
2797   case 78:
2798 #line 681 "rcparse.y"
2799     {
2800               default_style = ES_LEFT | WS_BORDER | WS_TABSTOP;
2801               base_style = ES_LEFT | WS_BORDER | WS_TABSTOP;
2802               class.named = 0;
2803               class.u.id = CTL_EDIT;
2804               res_text_field = res_null_text;   
2805             }
2806     break;
2807
2808   case 79:
2809 #line 689 "rcparse.y"
2810     {
2811             (yyval.dialog_control) = (yyvsp[(3) - (3)].dialog_control);
2812           }
2813     break;
2814
2815   case 80:
2816 #line 693 "rcparse.y"
2817     {
2818               default_style = BS_GROUPBOX;
2819               base_style = BS_GROUPBOX;
2820               class.named = 0;
2821               class.u.id = CTL_BUTTON;
2822               res_text_field = (yyvsp[(2) - (2)].id);   
2823             }
2824     break;
2825
2826   case 81:
2827 #line 701 "rcparse.y"
2828     {
2829             (yyval.dialog_control) = (yyvsp[(4) - (4)].dialog_control);
2830           }
2831     break;
2832
2833   case 82:
2834 #line 705 "rcparse.y"
2835     {
2836               default_style = ES_LEFT | WS_BORDER | WS_TABSTOP;
2837               base_style = ES_LEFT | WS_BORDER | WS_TABSTOP;
2838               class.named = 0;
2839               class.u.id = CTL_EDIT;
2840               res_text_field = (yyvsp[(2) - (2)].id);   
2841             }
2842     break;
2843
2844   case 83:
2845 #line 713 "rcparse.y"
2846     {
2847             (yyval.dialog_control) = (yyvsp[(4) - (4)].dialog_control);
2848             if (dialog.ex == NULL)
2849               rcparse_warning (_("IEDIT requires DIALOGEX"));
2850             res_string_to_id (&(yyval.dialog_control)->class, "HEDIT");
2851           }
2852     break;
2853
2854   case 84:
2855 #line 720 "rcparse.y"
2856     {
2857             (yyval.dialog_control) = define_icon_control ((yyvsp[(2) - (6)].id), (yyvsp[(3) - (6)].il), (yyvsp[(4) - (6)].il), (yyvsp[(5) - (6)].il), 0, 0, 0, (yyvsp[(6) - (6)].rcdata_item),
2858                                       dialog.ex);
2859           }
2860     break;
2861
2862   case 85:
2863 #line 726 "rcparse.y"
2864     {
2865             (yyval.dialog_control) = define_icon_control ((yyvsp[(2) - (8)].id), (yyvsp[(3) - (8)].il), (yyvsp[(4) - (8)].il), (yyvsp[(5) - (8)].il), 0, 0, 0, (yyvsp[(8) - (8)].rcdata_item),
2866                                       dialog.ex);
2867           }
2868     break;
2869
2870   case 86:
2871 #line 732 "rcparse.y"
2872     {
2873             (yyval.dialog_control) = define_icon_control ((yyvsp[(2) - (10)].id), (yyvsp[(3) - (10)].il), (yyvsp[(4) - (10)].il), (yyvsp[(5) - (10)].il), style, (yyvsp[(9) - (10)].il), 0, (yyvsp[(10) - (10)].rcdata_item),
2874                                       dialog.ex);
2875           }
2876     break;
2877
2878   case 87:
2879 #line 738 "rcparse.y"
2880     {
2881             (yyval.dialog_control) = define_icon_control ((yyvsp[(2) - (11)].id), (yyvsp[(3) - (11)].il), (yyvsp[(4) - (11)].il), (yyvsp[(5) - (11)].il), style, (yyvsp[(9) - (11)].il), (yyvsp[(10) - (11)].il), (yyvsp[(11) - (11)].rcdata_item),
2882                                       dialog.ex);
2883           }
2884     break;
2885
2886   case 88:
2887 #line 743 "rcparse.y"
2888     {
2889               default_style = ES_LEFT | WS_BORDER | WS_TABSTOP;
2890               base_style = ES_LEFT | WS_BORDER | WS_TABSTOP;
2891               class.named = 0;
2892               class.u.id = CTL_EDIT;
2893               res_text_field = (yyvsp[(2) - (2)].id);   
2894             }
2895     break;
2896
2897   case 89:
2898 #line 751 "rcparse.y"
2899     {
2900             (yyval.dialog_control) = (yyvsp[(4) - (4)].dialog_control);
2901             if (dialog.ex == NULL)
2902               rcparse_warning (_("IEDIT requires DIALOGEX"));
2903             res_string_to_id (&(yyval.dialog_control)->class, "IEDIT");
2904           }
2905     break;
2906
2907   case 90:
2908 #line 758 "rcparse.y"
2909     {
2910               default_style = LBS_NOTIFY | WS_BORDER;
2911               base_style = LBS_NOTIFY | WS_BORDER;
2912               class.named = 0;
2913               class.u.id = CTL_LISTBOX;
2914               res_text_field = res_null_text;   
2915             }
2916     break;
2917
2918   case 91:
2919 #line 766 "rcparse.y"
2920     {
2921             (yyval.dialog_control) = (yyvsp[(3) - (3)].dialog_control);
2922           }
2923     break;
2924
2925   case 92:
2926 #line 770 "rcparse.y"
2927     {
2928               default_style = SS_LEFT | WS_GROUP;
2929               base_style = SS_LEFT;
2930               class.named = 0;
2931               class.u.id = CTL_STATIC;
2932               res_text_field = (yyvsp[(2) - (2)].id);   
2933             }
2934     break;
2935
2936   case 93:
2937 #line 778 "rcparse.y"
2938     {
2939             (yyval.dialog_control) = (yyvsp[(4) - (4)].dialog_control);
2940           }
2941     break;
2942
2943   case 94:
2944 #line 782 "rcparse.y"
2945     {
2946               default_style = BS_PUSHBOX | WS_TABSTOP;
2947               base_style = BS_PUSHBOX;
2948               class.named = 0;
2949               class.u.id = CTL_BUTTON;
2950             }
2951     break;
2952
2953   case 95:
2954 #line 789 "rcparse.y"
2955     {
2956             (yyval.dialog_control) = (yyvsp[(4) - (4)].dialog_control);
2957           }
2958     break;
2959
2960   case 96:
2961 #line 793 "rcparse.y"
2962     {
2963               default_style = BS_PUSHBUTTON | WS_TABSTOP;
2964               base_style = BS_PUSHBUTTON | WS_TABSTOP;
2965               class.named = 0;
2966               class.u.id = CTL_BUTTON;
2967               res_text_field = (yyvsp[(2) - (2)].id);   
2968             }
2969     break;
2970
2971   case 97:
2972 #line 801 "rcparse.y"
2973     {
2974             (yyval.dialog_control) = (yyvsp[(4) - (4)].dialog_control);
2975           }
2976     break;
2977
2978   case 98:
2979 #line 805 "rcparse.y"
2980     {
2981               default_style = BS_RADIOBUTTON | WS_TABSTOP;
2982               base_style = BS_RADIOBUTTON;
2983               class.named = 0;
2984               class.u.id = CTL_BUTTON;
2985               res_text_field = (yyvsp[(2) - (2)].id);   
2986             }
2987     break;
2988
2989   case 99:
2990 #line 813 "rcparse.y"
2991     {
2992             (yyval.dialog_control) = (yyvsp[(4) - (4)].dialog_control);
2993           }
2994     break;
2995
2996   case 100:
2997 #line 817 "rcparse.y"
2998     {
2999               default_style = SS_RIGHT | WS_GROUP;
3000               base_style = SS_RIGHT;
3001               class.named = 0;
3002               class.u.id = CTL_STATIC;
3003               res_text_field = (yyvsp[(2) - (2)].id);   
3004             }
3005     break;
3006
3007   case 101:
3008 #line 825 "rcparse.y"
3009     {
3010             (yyval.dialog_control) = (yyvsp[(4) - (4)].dialog_control);
3011           }
3012     break;
3013
3014   case 102:
3015 #line 829 "rcparse.y"
3016     {
3017               default_style = SBS_HORZ;
3018               base_style = 0;
3019               class.named = 0;
3020               class.u.id = CTL_SCROLLBAR;
3021               res_text_field = res_null_text;   
3022             }
3023     break;
3024
3025   case 103:
3026 #line 837 "rcparse.y"
3027     {
3028             (yyval.dialog_control) = (yyvsp[(3) - (3)].dialog_control);
3029           }
3030     break;
3031
3032   case 104:
3033 #line 841 "rcparse.y"
3034     {
3035               default_style = BS_3STATE | WS_TABSTOP;
3036               base_style = BS_3STATE;
3037               class.named = 0;
3038               class.u.id = CTL_BUTTON;
3039               res_text_field = (yyvsp[(2) - (2)].id);   
3040             }
3041     break;
3042
3043   case 105:
3044 #line 849 "rcparse.y"
3045     {
3046             (yyval.dialog_control) = (yyvsp[(4) - (4)].dialog_control);
3047           }
3048     break;
3049
3050   case 106:
3051 #line 854 "rcparse.y"
3052     { style = WS_CHILD | WS_VISIBLE; }
3053     break;
3054
3055   case 107:
3056 #line 856 "rcparse.y"
3057     {
3058             rc_res_id cid;
3059             cid.named = 0;
3060             cid.u.id = CTL_BUTTON;
3061             (yyval.dialog_control) = define_control ((yyvsp[(2) - (15)].id), (yyvsp[(3) - (15)].il), (yyvsp[(5) - (15)].il), (yyvsp[(7) - (15)].il), (yyvsp[(9) - (15)].il), (yyvsp[(11) - (15)].il), cid,
3062                                  style, (yyvsp[(15) - (15)].il));
3063           }
3064     break;
3065
3066   case 108:
3067 #line 874 "rcparse.y"
3068     {
3069             (yyval.dialog_control) = define_control (res_text_field, (yyvsp[(1) - (6)].il), (yyvsp[(2) - (6)].il), (yyvsp[(3) - (6)].il), (yyvsp[(4) - (6)].il), (yyvsp[(5) - (6)].il), class,
3070                                  default_style | WS_CHILD | WS_VISIBLE, 0);
3071             if ((yyvsp[(6) - (6)].rcdata_item) != NULL)
3072               {
3073                 if (dialog.ex == NULL)
3074                   rcparse_warning (_("control data requires DIALOGEX"));
3075                 (yyval.dialog_control)->data = (yyvsp[(6) - (6)].rcdata_item);
3076               }
3077           }
3078     break;
3079
3080   case 109:
3081 #line 886 "rcparse.y"
3082     {
3083             (yyval.dialog_control) = define_control (res_text_field, (yyvsp[(1) - (8)].il), (yyvsp[(2) - (8)].il), (yyvsp[(3) - (8)].il), (yyvsp[(4) - (8)].il), (yyvsp[(5) - (8)].il), class, style, (yyvsp[(7) - (8)].il));
3084             if ((yyvsp[(8) - (8)].rcdata_item) != NULL)
3085               {
3086                 if (dialog.ex == NULL)
3087                   rcparse_warning (_("control data requires DIALOGEX"));
3088                 (yyval.dialog_control)->data = (yyvsp[(8) - (8)].rcdata_item);
3089               }
3090           }
3091     break;
3092
3093   case 110:
3094 #line 897 "rcparse.y"
3095     {
3096             (yyval.dialog_control) = define_control (res_text_field, (yyvsp[(1) - (9)].il), (yyvsp[(2) - (9)].il), (yyvsp[(3) - (9)].il), (yyvsp[(4) - (9)].il), (yyvsp[(5) - (9)].il), class, style, (yyvsp[(7) - (9)].il));
3097             if (dialog.ex == NULL)
3098               rcparse_warning (_("help ID requires DIALOGEX"));
3099             (yyval.dialog_control)->help = (yyvsp[(8) - (9)].il);
3100             (yyval.dialog_control)->data = (yyvsp[(9) - (9)].rcdata_item);
3101           }
3102     break;
3103
3104   case 111:
3105 #line 908 "rcparse.y"
3106     {
3107             if ((yyvsp[(2) - (2)].id).named)
3108               res_unistring_to_id (&(yyval.id), (yyvsp[(2) - (2)].id).u.n.name);
3109             else
3110               (yyval.id)=(yyvsp[(2) - (2)].id);
3111           }
3112     break;
3113
3114   case 112:
3115 #line 918 "rcparse.y"
3116     {
3117             res_string_to_id (&(yyval.id), "");
3118           }
3119     break;
3120
3121   case 113:
3122 #line 921 "rcparse.y"
3123     { (yyval.id)=(yyvsp[(1) - (2)].id); }
3124     break;
3125
3126   case 114:
3127 #line 926 "rcparse.y"
3128     {
3129             (yyval.id).named = 0;
3130             (yyval.id).u.id = (yyvsp[(1) - (1)].il);
3131           }
3132     break;
3133
3134   case 115:
3135 #line 931 "rcparse.y"
3136     {
3137             (yyval.id).named = 1;
3138             (yyval.id).u.n.name = (yyvsp[(1) - (1)].uni);
3139             (yyval.id).u.n.length = unichar_len ((yyvsp[(1) - (1)].uni));
3140           }
3141     break;
3142
3143   case 116:
3144 #line 940 "rcparse.y"
3145     {
3146             (yyval.rcdata_item) = NULL;
3147           }
3148     break;
3149
3150   case 117:
3151 #line 944 "rcparse.y"
3152     {
3153             (yyval.rcdata_item) = (yyvsp[(2) - (3)].rcdata).first;
3154           }
3155     break;
3156
3157   case 118:
3158 #line 953 "rcparse.y"
3159     { style = WS_CHILD | WS_VISIBLE; }
3160     break;
3161
3162   case 120:
3163 #line 959 "rcparse.y"
3164     { style = SS_ICON | WS_CHILD | WS_VISIBLE; }
3165     break;
3166
3167   case 122:
3168 #line 965 "rcparse.y"
3169     { style = base_style | WS_CHILD | WS_VISIBLE; }
3170     break;
3171
3172   case 124:
3173 #line 973 "rcparse.y"
3174     {
3175             define_font ((yyvsp[(1) - (4)].id), &(yyvsp[(3) - (4)].res_info), (yyvsp[(4) - (4)].s));
3176             if (yychar != YYEMPTY)
3177               YYERROR;
3178             rcparse_discard_strings ();
3179           }
3180     break;
3181
3182   case 125:
3183 #line 985 "rcparse.y"
3184     {
3185             define_icon ((yyvsp[(1) - (4)].id), &(yyvsp[(3) - (4)].res_info), (yyvsp[(4) - (4)].s));
3186             if (yychar != YYEMPTY)
3187               YYERROR;
3188             rcparse_discard_strings ();
3189           }
3190     break;
3191
3192   case 126:
3193 #line 998 "rcparse.y"
3194     {
3195             language = (yyvsp[(2) - (3)].il) | ((yyvsp[(3) - (3)].il) << SUBLANG_SHIFT);
3196           }
3197     break;
3198
3199   case 127:
3200 #line 1007 "rcparse.y"
3201     {
3202             define_menu ((yyvsp[(1) - (6)].id), &(yyvsp[(3) - (6)].res_info), (yyvsp[(5) - (6)].menuitem));
3203             if (yychar != YYEMPTY)
3204               YYERROR;
3205             rcparse_discard_strings ();
3206           }
3207     break;
3208
3209   case 128:
3210 #line 1017 "rcparse.y"
3211     {
3212             (yyval.menuitem) = NULL;
3213           }
3214     break;
3215
3216   case 129:
3217 #line 1021 "rcparse.y"
3218     {
3219             if ((yyvsp[(1) - (2)].menuitem) == NULL)
3220               (yyval.menuitem) = (yyvsp[(2) - (2)].menuitem);
3221             else
3222               {
3223                 rc_menuitem **pp;
3224
3225                 for (pp = &(yyvsp[(1) - (2)].menuitem)->next; *pp != NULL; pp = &(*pp)->next)
3226                   ;
3227                 *pp = (yyvsp[(2) - (2)].menuitem);
3228                 (yyval.menuitem) = (yyvsp[(1) - (2)].menuitem);
3229               }
3230           }
3231     break;
3232
3233   case 130:
3234 #line 1038 "rcparse.y"
3235     {
3236             (yyval.menuitem) = define_menuitem ((yyvsp[(2) - (4)].uni), (yyvsp[(3) - (4)].il), (yyvsp[(4) - (4)].is), 0, 0, NULL);
3237           }
3238     break;
3239
3240   case 131:
3241 #line 1042 "rcparse.y"
3242     {
3243             (yyval.menuitem) = define_menuitem (NULL, 0, 0, 0, 0, NULL);
3244           }
3245     break;
3246
3247   case 132:
3248 #line 1046 "rcparse.y"
3249     {
3250             (yyval.menuitem) = define_menuitem ((yyvsp[(2) - (6)].uni), 0, (yyvsp[(3) - (6)].is), 0, 0, (yyvsp[(5) - (6)].menuitem));
3251           }
3252     break;
3253
3254   case 133:
3255 #line 1053 "rcparse.y"
3256     {
3257             (yyval.is) = 0;
3258           }
3259     break;
3260
3261   case 134:
3262 #line 1057 "rcparse.y"
3263     {
3264             (yyval.is) = (yyvsp[(1) - (3)].is) | (yyvsp[(3) - (3)].is);
3265           }
3266     break;
3267
3268   case 135:
3269 #line 1061 "rcparse.y"
3270     {
3271             (yyval.is) = (yyvsp[(1) - (2)].is) | (yyvsp[(2) - (2)].is);
3272           }
3273     break;
3274
3275   case 136:
3276 #line 1068 "rcparse.y"
3277     {
3278             (yyval.is) = MENUITEM_CHECKED;
3279           }
3280     break;
3281
3282   case 137:
3283 #line 1072 "rcparse.y"
3284     {
3285             (yyval.is) = MENUITEM_GRAYED;
3286           }
3287     break;
3288
3289   case 138:
3290 #line 1076 "rcparse.y"
3291     {
3292             (yyval.is) = MENUITEM_HELP;
3293           }
3294     break;
3295
3296   case 139:
3297 #line 1080 "rcparse.y"
3298     {
3299             (yyval.is) = MENUITEM_INACTIVE;
3300           }
3301     break;
3302
3303   case 140:
3304 #line 1084 "rcparse.y"
3305     {
3306             (yyval.is) = MENUITEM_MENUBARBREAK;
3307           }
3308     break;
3309
3310   case 141:
3311 #line 1088 "rcparse.y"
3312     {
3313             (yyval.is) = MENUITEM_MENUBREAK;
3314           }
3315     break;
3316
3317   case 142:
3318 #line 1097 "rcparse.y"
3319     {
3320             define_menu ((yyvsp[(1) - (6)].id), &(yyvsp[(3) - (6)].res_info), (yyvsp[(5) - (6)].menuitem));
3321             if (yychar != YYEMPTY)
3322               YYERROR;
3323             rcparse_discard_strings ();
3324           }
3325     break;
3326
3327   case 143:
3328 #line 1107 "rcparse.y"
3329     {
3330             (yyval.menuitem) = NULL;
3331           }
3332     break;
3333
3334   case 144:
3335 #line 1111 "rcparse.y"
3336     {
3337             if ((yyvsp[(1) - (2)].menuitem) == NULL)
3338               (yyval.menuitem) = (yyvsp[(2) - (2)].menuitem);
3339             else
3340               {
3341                 rc_menuitem **pp;
3342
3343                 for (pp = &(yyvsp[(1) - (2)].menuitem)->next; *pp != NULL; pp = &(*pp)->next)
3344                   ;
3345                 *pp = (yyvsp[(2) - (2)].menuitem);
3346                 (yyval.menuitem) = (yyvsp[(1) - (2)].menuitem);
3347               }
3348           }
3349     break;
3350
3351   case 145:
3352 #line 1128 "rcparse.y"
3353     {
3354             (yyval.menuitem) = define_menuitem ((yyvsp[(2) - (2)].uni), 0, 0, 0, 0, NULL);
3355           }
3356     break;
3357
3358   case 146:
3359 #line 1132 "rcparse.y"
3360     {
3361             (yyval.menuitem) = define_menuitem ((yyvsp[(2) - (3)].uni), (yyvsp[(3) - (3)].il), 0, 0, 0, NULL);
3362           }
3363     break;
3364
3365   case 147:
3366 #line 1136 "rcparse.y"
3367     {
3368             (yyval.menuitem) = define_menuitem ((yyvsp[(2) - (5)].uni), (yyvsp[(3) - (5)].il), (yyvsp[(4) - (5)].il), (yyvsp[(5) - (5)].il), 0, NULL);
3369           }
3370     break;
3371
3372   case 148:
3373 #line 1140 "rcparse.y"
3374     {
3375             (yyval.menuitem) = define_menuitem (NULL, 0, 0, 0, 0, NULL);
3376           }
3377     break;
3378
3379   case 149:
3380 #line 1144 "rcparse.y"
3381     {
3382             (yyval.menuitem) = define_menuitem ((yyvsp[(2) - (5)].uni), 0, 0, 0, 0, (yyvsp[(4) - (5)].menuitem));
3383           }
3384     break;
3385
3386   case 150:
3387 #line 1148 "rcparse.y"
3388     {
3389             (yyval.menuitem) = define_menuitem ((yyvsp[(2) - (6)].uni), (yyvsp[(3) - (6)].il), 0, 0, 0, (yyvsp[(5) - (6)].menuitem));
3390           }
3391     break;
3392
3393   case 151:
3394 #line 1152 "rcparse.y"
3395     {
3396             (yyval.menuitem) = define_menuitem ((yyvsp[(2) - (7)].uni), (yyvsp[(3) - (7)].il), (yyvsp[(4) - (7)].il), 0, 0, (yyvsp[(6) - (7)].menuitem));
3397           }
3398     break;
3399
3400   case 152:
3401 #line 1157 "rcparse.y"
3402     {
3403             (yyval.menuitem) = define_menuitem ((yyvsp[(2) - (9)].uni), (yyvsp[(3) - (9)].il), (yyvsp[(4) - (9)].il), (yyvsp[(5) - (9)].il), (yyvsp[(6) - (9)].il), (yyvsp[(8) - (9)].menuitem));
3404           }
3405     break;
3406
3407   case 153:
3408 #line 1166 "rcparse.y"
3409     {
3410             define_messagetable ((yyvsp[(1) - (4)].id), &(yyvsp[(3) - (4)].res_info), (yyvsp[(4) - (4)].s));
3411             if (yychar != YYEMPTY)
3412               YYERROR;
3413             rcparse_discard_strings ();
3414           }
3415     break;
3416
3417   case 154:
3418 #line 1178 "rcparse.y"
3419     {
3420             rcparse_rcdata ();
3421           }
3422     break;
3423
3424   case 155:
3425 #line 1182 "rcparse.y"
3426     {
3427             rcparse_normal ();
3428             (yyval.rcdata) = (yyvsp[(2) - (2)].rcdata);
3429           }
3430     break;
3431
3432   case 156:
3433 #line 1190 "rcparse.y"
3434     {
3435             (yyval.rcdata).first = NULL;
3436             (yyval.rcdata).last = NULL;
3437           }
3438     break;
3439
3440   case 157:
3441 #line 1195 "rcparse.y"
3442     {
3443             (yyval.rcdata) = (yyvsp[(1) - (1)].rcdata);
3444           }
3445     break;
3446
3447   case 158:
3448 #line 1202 "rcparse.y"
3449     {
3450             rc_rcdata_item *ri;
3451
3452             ri = define_rcdata_string ((yyvsp[(1) - (1)].ss).s, (yyvsp[(1) - (1)].ss).length);
3453             (yyval.rcdata).first = ri;
3454             (yyval.rcdata).last = ri;
3455           }
3456     break;
3457
3458   case 159:
3459 #line 1210 "rcparse.y"
3460     {
3461             rc_rcdata_item *ri;
3462
3463             ri = define_rcdata_unistring ((yyvsp[(1) - (1)].suni).s, (yyvsp[(1) - (1)].suni).length);
3464             (yyval.rcdata).first = ri;
3465             (yyval.rcdata).last = ri;
3466           }
3467     break;
3468
3469   case 160:
3470 #line 1218 "rcparse.y"
3471     {
3472             rc_rcdata_item *ri;
3473
3474             ri = define_rcdata_number ((yyvsp[(1) - (1)].i).val, (yyvsp[(1) - (1)].i).dword);
3475             (yyval.rcdata).first = ri;
3476             (yyval.rcdata).last = ri;
3477           }
3478     break;
3479
3480   case 161:
3481 #line 1226 "rcparse.y"
3482     {
3483             rc_rcdata_item *ri;
3484
3485             ri = define_rcdata_string ((yyvsp[(3) - (3)].ss).s, (yyvsp[(3) - (3)].ss).length);
3486             (yyval.rcdata).first = (yyvsp[(1) - (3)].rcdata).first;
3487             (yyvsp[(1) - (3)].rcdata).last->next = ri;
3488             (yyval.rcdata).last = ri;
3489           }
3490     break;
3491
3492   case 162:
3493 #line 1235 "rcparse.y"
3494     {
3495             rc_rcdata_item *ri;
3496
3497             ri = define_rcdata_unistring ((yyvsp[(3) - (3)].suni).s, (yyvsp[(3) - (3)].suni).length);
3498             (yyval.rcdata).first = (yyvsp[(1) - (3)].rcdata).first;
3499             (yyvsp[(1) - (3)].rcdata).last->next = ri;
3500             (yyval.rcdata).last = ri;
3501           }
3502     break;
3503
3504   case 163:
3505 #line 1244 "rcparse.y"
3506     {
3507             rc_rcdata_item *ri;
3508
3509             ri = define_rcdata_number ((yyvsp[(3) - (3)].i).val, (yyvsp[(3) - (3)].i).dword);
3510             (yyval.rcdata).first = (yyvsp[(1) - (3)].rcdata).first;
3511             (yyvsp[(1) - (3)].rcdata).last->next = ri;
3512             (yyval.rcdata).last = ri;
3513           }
3514     break;
3515
3516   case 164:
3517 #line 1253 "rcparse.y"
3518     {
3519             (yyval.rcdata)=(yyvsp[(1) - (2)].rcdata);
3520           }
3521     break;
3522
3523   case 165:
3524 #line 1262 "rcparse.y"
3525     { sub_res_info = (yyvsp[(2) - (3)].res_info); rcparse_rcdata (); }
3526     break;
3527
3528   case 166:
3529 #line 1263 "rcparse.y"
3530     { rcparse_normal (); }
3531     break;
3532
3533   case 168:
3534 #line 1269 "rcparse.y"
3535     {
3536             define_stringtable (&sub_res_info, (yyvsp[(2) - (3)].il), (yyvsp[(3) - (3)].suni).s, (yyvsp[(3) - (3)].suni).length);
3537             rcparse_discard_strings ();
3538           }
3539     break;
3540
3541   case 169:
3542 #line 1274 "rcparse.y"
3543     {
3544             define_stringtable (&sub_res_info, (yyvsp[(2) - (4)].il), (yyvsp[(4) - (4)].suni).s, (yyvsp[(4) - (4)].suni).length);
3545             rcparse_discard_strings ();
3546           }
3547     break;
3548
3549   case 170:
3550 #line 1279 "rcparse.y"
3551     {
3552             rcparse_warning (_("invalid stringtable resource."));
3553             abort ();
3554           }
3555     break;
3556
3557   case 171:
3558 #line 1287 "rcparse.y"
3559     {
3560             (yyval.id)=(yyvsp[(1) - (1)].id);
3561           }
3562     break;
3563
3564   case 172:
3565 #line 1291 "rcparse.y"
3566     {
3567           (yyval.id).named = 0;
3568           (yyval.id).u.id = 23;
3569         }
3570     break;
3571
3572   case 173:
3573 #line 1296 "rcparse.y"
3574     {
3575           (yyval.id).named = 0;
3576           (yyval.id).u.id = RT_RCDATA;
3577         }
3578     break;
3579
3580   case 174:
3581 #line 1301 "rcparse.y"
3582     {
3583           (yyval.id).named = 0;
3584           (yyval.id).u.id = RT_MANIFEST;
3585         }
3586     break;
3587
3588   case 175:
3589 #line 1306 "rcparse.y"
3590     {
3591           (yyval.id).named = 0;
3592           (yyval.id).u.id = RT_PLUGPLAY;
3593         }
3594     break;
3595
3596   case 176:
3597 #line 1311 "rcparse.y"
3598     {
3599           (yyval.id).named = 0;
3600           (yyval.id).u.id = RT_VXD;
3601         }
3602     break;
3603
3604   case 177:
3605 #line 1316 "rcparse.y"
3606     {
3607           (yyval.id).named = 0;
3608           (yyval.id).u.id = RT_DLGINCLUDE;
3609         }
3610     break;
3611
3612   case 178:
3613 #line 1321 "rcparse.y"
3614     {
3615           (yyval.id).named = 0;
3616           (yyval.id).u.id = RT_DLGINIT;
3617         }
3618     break;
3619
3620   case 179:
3621 #line 1326 "rcparse.y"
3622     {
3623           (yyval.id).named = 0;
3624           (yyval.id).u.id = RT_ANICURSOR;
3625         }
3626     break;
3627
3628   case 180:
3629 #line 1331 "rcparse.y"
3630     {
3631           (yyval.id).named = 0;
3632           (yyval.id).u.id = RT_ANIICON;
3633         }
3634     break;
3635
3636   case 181:
3637 #line 1342 "rcparse.y"
3638     {
3639             define_user_data ((yyvsp[(1) - (6)].id), (yyvsp[(2) - (6)].id), &(yyvsp[(3) - (6)].res_info), (yyvsp[(5) - (6)].rcdata).first);
3640             if (yychar != YYEMPTY)
3641               YYERROR;
3642             rcparse_discard_strings ();
3643           }
3644     break;
3645
3646   case 182:
3647 #line 1349 "rcparse.y"
3648     {
3649             define_user_file ((yyvsp[(1) - (4)].id), (yyvsp[(2) - (4)].id), &(yyvsp[(3) - (4)].res_info), (yyvsp[(4) - (4)].s));
3650             if (yychar != YYEMPTY)
3651               YYERROR;
3652             rcparse_discard_strings ();
3653           }
3654     break;
3655
3656   case 183:
3657 #line 1359 "rcparse.y"
3658     {
3659           define_toolbar ((yyvsp[(1) - (8)].id), &(yyvsp[(3) - (8)].res_info), (yyvsp[(4) - (8)].il), (yyvsp[(5) - (8)].il), (yyvsp[(7) - (8)].toobar_item));
3660         }
3661     break;
3662
3663   case 184:
3664 #line 1364 "rcparse.y"
3665     { (yyval.toobar_item)= NULL; }
3666     break;
3667
3668   case 185:
3669 #line 1366 "rcparse.y"
3670     {
3671           rc_toolbar_item *c,*n;
3672           c = (yyvsp[(1) - (3)].toobar_item);
3673           n= (rc_toolbar_item *)
3674               res_alloc (sizeof (rc_toolbar_item));
3675           if (c != NULL)
3676             while (c->next != NULL)
3677               c = c->next;
3678           n->prev = c;
3679           n->next = NULL;
3680           if (c != NULL)
3681             c->next = n;
3682           n->id = (yyvsp[(3) - (3)].id);
3683           if ((yyvsp[(1) - (3)].toobar_item) == NULL)
3684             (yyval.toobar_item) = n;
3685           else
3686             (yyval.toobar_item) = (yyvsp[(1) - (3)].toobar_item);
3687         }
3688     break;
3689
3690   case 186:
3691 #line 1385 "rcparse.y"
3692     {
3693           rc_toolbar_item *c,*n;
3694           c = (yyvsp[(1) - (2)].toobar_item);
3695           n= (rc_toolbar_item *)
3696               res_alloc (sizeof (rc_toolbar_item));
3697           if (c != NULL)
3698             while (c->next != NULL)
3699               c = c->next;
3700           n->prev = c;
3701           n->next = NULL;
3702           if (c != NULL)
3703             c->next = n;
3704           n->id.named = 0;
3705           n->id.u.id = 0;
3706           if ((yyvsp[(1) - (2)].toobar_item) == NULL)
3707             (yyval.toobar_item) = n;
3708           else
3709             (yyval.toobar_item) = (yyvsp[(1) - (2)].toobar_item);
3710         }
3711     break;
3712
3713   case 187:
3714 #line 1410 "rcparse.y"
3715     {
3716             define_versioninfo ((yyvsp[(1) - (6)].id), language, (yyvsp[(3) - (6)].fixver), (yyvsp[(5) - (6)].verinfo));
3717             if (yychar != YYEMPTY)
3718               YYERROR;
3719             rcparse_discard_strings ();
3720           }
3721     break;
3722
3723   case 188:
3724 #line 1420 "rcparse.y"
3725     {
3726             (yyval.fixver) = ((rc_fixed_versioninfo *)
3727                   res_alloc (sizeof (rc_fixed_versioninfo)));
3728             memset ((yyval.fixver), 0, sizeof (rc_fixed_versioninfo));
3729           }
3730     break;
3731
3732   case 189:
3733 #line 1427 "rcparse.y"
3734     {
3735             (yyvsp[(1) - (6)].fixver)->file_version_ms = ((yyvsp[(3) - (6)].il) << 16) | ((yyvsp[(4) - (6)].il) & 0xffff);
3736             (yyvsp[(1) - (6)].fixver)->file_version_ls = ((yyvsp[(5) - (6)].il) << 16) | ((yyvsp[(6) - (6)].il) & 0xffff);
3737             (yyval.fixver) = (yyvsp[(1) - (6)].fixver);
3738           }
3739     break;
3740
3741   case 190:
3742 #line 1434 "rcparse.y"
3743     {
3744             (yyvsp[(1) - (6)].fixver)->product_version_ms = ((yyvsp[(3) - (6)].il) << 16) | ((yyvsp[(4) - (6)].il) & 0xffff);
3745             (yyvsp[(1) - (6)].fixver)->product_version_ls = ((yyvsp[(5) - (6)].il) << 16) | ((yyvsp[(6) - (6)].il) & 0xffff);
3746             (yyval.fixver) = (yyvsp[(1) - (6)].fixver);
3747           }
3748     break;
3749
3750   case 191:
3751 #line 1440 "rcparse.y"
3752     {
3753             (yyvsp[(1) - (3)].fixver)->file_flags_mask = (yyvsp[(3) - (3)].il);
3754             (yyval.fixver) = (yyvsp[(1) - (3)].fixver);
3755           }
3756     break;
3757
3758   case 192:
3759 #line 1445 "rcparse.y"
3760     {
3761             (yyvsp[(1) - (3)].fixver)->file_flags = (yyvsp[(3) - (3)].il);
3762             (yyval.fixver) = (yyvsp[(1) - (3)].fixver);
3763           }
3764     break;
3765
3766   case 193:
3767 #line 1450 "rcparse.y"
3768     {
3769             (yyvsp[(1) - (3)].fixver)->file_os = (yyvsp[(3) - (3)].il);
3770             (yyval.fixver) = (yyvsp[(1) - (3)].fixver);
3771           }
3772     break;
3773
3774   case 194:
3775 #line 1455 "rcparse.y"
3776     {
3777             (yyvsp[(1) - (3)].fixver)->file_type = (yyvsp[(3) - (3)].il);
3778             (yyval.fixver) = (yyvsp[(1) - (3)].fixver);
3779           }
3780     break;
3781
3782   case 195:
3783 #line 1460 "rcparse.y"
3784     {
3785             (yyvsp[(1) - (3)].fixver)->file_subtype = (yyvsp[(3) - (3)].il);
3786             (yyval.fixver) = (yyvsp[(1) - (3)].fixver);
3787           }
3788     break;
3789
3790   case 196:
3791 #line 1474 "rcparse.y"
3792     {
3793             (yyval.verinfo) = NULL;
3794           }
3795     break;
3796
3797   case 197:
3798 #line 1478 "rcparse.y"
3799     {
3800             (yyval.verinfo) = append_ver_stringfileinfo ((yyvsp[(1) - (5)].verinfo), (yyvsp[(4) - (5)].verstringtable));
3801           }
3802     break;
3803
3804   case 198:
3805 #line 1482 "rcparse.y"
3806     {
3807             (yyval.verinfo) = append_ver_varfileinfo ((yyvsp[(1) - (7)].verinfo), (yyvsp[(5) - (7)].uni), (yyvsp[(6) - (7)].vervar));
3808           }
3809     break;
3810
3811   case 199:
3812 #line 1489 "rcparse.y"
3813     {
3814             (yyval.verstringtable) = NULL;
3815           }
3816     break;
3817
3818   case 200:
3819 #line 1493 "rcparse.y"
3820     {
3821             (yyval.verstringtable) = append_ver_stringtable ((yyvsp[(1) - (5)].verstringtable), (yyvsp[(2) - (5)].s), (yyvsp[(4) - (5)].verstring));
3822           }
3823     break;
3824
3825   case 201:
3826 #line 1500 "rcparse.y"
3827     {
3828             (yyval.verstring) = NULL;
3829           }
3830     break;
3831
3832   case 202:
3833 #line 1504 "rcparse.y"
3834     {
3835             (yyval.verstring) = append_verval ((yyvsp[(1) - (5)].verstring), (yyvsp[(3) - (5)].uni), (yyvsp[(5) - (5)].uni));
3836           }
3837     break;
3838
3839   case 203:
3840 #line 1511 "rcparse.y"
3841     {
3842             (yyval.vervar) = NULL;
3843           }
3844     break;
3845
3846   case 204:
3847 #line 1515 "rcparse.y"
3848     {
3849             (yyval.vervar) = append_vertrans ((yyvsp[(1) - (3)].vervar), (yyvsp[(2) - (3)].il), (yyvsp[(3) - (3)].il));
3850           }
3851     break;
3852
3853   case 205:
3854 #line 1524 "rcparse.y"
3855     {
3856             (yyval.id).named = 0;
3857             (yyval.id).u.id = (yyvsp[(1) - (1)].il);
3858           }
3859     break;
3860
3861   case 206:
3862 #line 1529 "rcparse.y"
3863     {
3864             res_unistring_to_id (&(yyval.id), (yyvsp[(1) - (1)].uni));
3865           }
3866     break;
3867
3868   case 207:
3869 #line 1538 "rcparse.y"
3870     {
3871             (yyval.uni) = (yyvsp[(1) - (1)].uni);
3872           }
3873     break;
3874
3875   case 208:
3876 #line 1542 "rcparse.y"
3877     {
3878             unichar *h = NULL;
3879             unicode_from_ascii ((rc_uint_type *) NULL, &h, (yyvsp[(1) - (1)].s));
3880             (yyval.uni) = h;
3881           }
3882     break;
3883
3884   case 209:
3885 #line 1552 "rcparse.y"
3886     {
3887             (yyval.id).named = 0;
3888             (yyval.id).u.id = (yyvsp[(1) - (2)].il);
3889           }
3890     break;
3891
3892   case 210:
3893 #line 1557 "rcparse.y"
3894     {
3895             res_unistring_to_id (&(yyval.id), (yyvsp[(1) - (1)].uni));
3896           }
3897     break;
3898
3899   case 211:
3900 #line 1561 "rcparse.y"
3901     {
3902             res_unistring_to_id (&(yyval.id), (yyvsp[(1) - (2)].uni));
3903           }
3904     break;
3905
3906   case 212:
3907 #line 1571 "rcparse.y"
3908     {
3909             memset (&(yyval.res_info), 0, sizeof (rc_res_res_info));
3910             (yyval.res_info).language = language;
3911             /* FIXME: Is this the right default?  */
3912             (yyval.res_info).memflags = MEMFLAG_MOVEABLE | MEMFLAG_PURE | MEMFLAG_DISCARDABLE;
3913           }
3914     break;
3915
3916   case 213:
3917 #line 1578 "rcparse.y"
3918     {
3919             (yyval.res_info) = (yyvsp[(1) - (2)].res_info);
3920             (yyval.res_info).memflags |= (yyvsp[(2) - (2)].memflags).on;
3921             (yyval.res_info).memflags &=~ (yyvsp[(2) - (2)].memflags).off;
3922           }
3923     break;
3924
3925   case 214:
3926 #line 1584 "rcparse.y"
3927     {
3928             (yyval.res_info) = (yyvsp[(1) - (3)].res_info);
3929             (yyval.res_info).characteristics = (yyvsp[(3) - (3)].il);
3930           }
3931     break;
3932
3933   case 215:
3934 #line 1589 "rcparse.y"
3935     {
3936             (yyval.res_info) = (yyvsp[(1) - (4)].res_info);
3937             (yyval.res_info).language = (yyvsp[(3) - (4)].il) | ((yyvsp[(4) - (4)].il) << SUBLANG_SHIFT);
3938           }
3939     break;
3940
3941   case 216:
3942 #line 1594 "rcparse.y"
3943     {
3944             (yyval.res_info) = (yyvsp[(1) - (3)].res_info);
3945             (yyval.res_info).version = (yyvsp[(3) - (3)].il);
3946           }
3947     break;
3948
3949   case 217:
3950 #line 1604 "rcparse.y"
3951     {
3952             memset (&(yyval.res_info), 0, sizeof (rc_res_res_info));
3953             (yyval.res_info).language = language;
3954             (yyval.res_info).memflags = MEMFLAG_MOVEABLE | MEMFLAG_DISCARDABLE;
3955           }
3956     break;
3957
3958   case 218:
3959 #line 1610 "rcparse.y"
3960     {
3961             (yyval.res_info) = (yyvsp[(1) - (2)].res_info);
3962             (yyval.res_info).memflags |= (yyvsp[(2) - (2)].memflags).on;
3963             (yyval.res_info).memflags &=~ (yyvsp[(2) - (2)].memflags).off;
3964           }
3965     break;
3966
3967   case 219:
3968 #line 1621 "rcparse.y"
3969     {
3970             memset (&(yyval.res_info), 0, sizeof (rc_res_res_info));
3971             (yyval.res_info).language = language;
3972             (yyval.res_info).memflags = MEMFLAG_MOVEABLE | MEMFLAG_PURE | MEMFLAG_DISCARDABLE;
3973           }
3974     break;
3975
3976   case 220:
3977 #line 1627 "rcparse.y"
3978     {
3979             (yyval.res_info) = (yyvsp[(1) - (2)].res_info);
3980             (yyval.res_info).memflags |= (yyvsp[(2) - (2)].memflags).on;
3981             (yyval.res_info).memflags &=~ (yyvsp[(2) - (2)].memflags).off;
3982           }
3983     break;
3984
3985   case 221:
3986 #line 1639 "rcparse.y"
3987     {
3988             (yyval.memflags).on = MEMFLAG_MOVEABLE;
3989             (yyval.memflags).off = 0;
3990           }
3991     break;
3992
3993   case 222:
3994 #line 1644 "rcparse.y"
3995     {
3996             (yyval.memflags).on = 0;
3997             (yyval.memflags).off = MEMFLAG_MOVEABLE;
3998           }
3999     break;
4000
4001   case 223:
4002 #line 1649 "rcparse.y"
4003     {
4004             (yyval.memflags).on = MEMFLAG_PURE;
4005             (yyval.memflags).off = 0;
4006           }
4007     break;
4008
4009   case 224:
4010 #line 1654 "rcparse.y"
4011     {
4012             (yyval.memflags).on = 0;
4013             (yyval.memflags).off = MEMFLAG_PURE;
4014           }
4015     break;
4016
4017   case 225:
4018 #line 1659 "rcparse.y"
4019     {
4020             (yyval.memflags).on = MEMFLAG_PRELOAD;
4021             (yyval.memflags).off = 0;
4022           }
4023     break;
4024
4025   case 226:
4026 #line 1664 "rcparse.y"
4027     {
4028             (yyval.memflags).on = 0;
4029             (yyval.memflags).off = MEMFLAG_PRELOAD;
4030           }
4031     break;
4032
4033   case 227:
4034 #line 1669 "rcparse.y"
4035     {
4036             (yyval.memflags).on = MEMFLAG_DISCARDABLE;
4037             (yyval.memflags).off = 0;
4038           }
4039     break;
4040
4041   case 228:
4042 #line 1679 "rcparse.y"
4043     {
4044             (yyval.s) = (yyvsp[(1) - (1)].s);
4045           }
4046     break;
4047
4048   case 229:
4049 #line 1683 "rcparse.y"
4050     {
4051             (yyval.s) = (yyvsp[(1) - (1)].s);
4052           }
4053     break;
4054
4055   case 230:
4056 #line 1691 "rcparse.y"
4057     {
4058             (yyval.uni) = (yyvsp[(1) - (1)].uni);
4059           }
4060     break;
4061
4062   case 231:
4063 #line 1696 "rcparse.y"
4064     {
4065             rc_uint_type l1 = unichar_len ((yyvsp[(1) - (2)].uni));
4066             rc_uint_type l2 = unichar_len ((yyvsp[(2) - (2)].uni));
4067             unichar *h = (unichar *) res_alloc ((l1 + l2 + 1) * sizeof (unichar));
4068             if (l1 != 0)
4069               memcpy (h, (yyvsp[(1) - (2)].uni), l1 * sizeof (unichar));
4070             if (l2 != 0)
4071               memcpy (h + l1, (yyvsp[(2) - (2)].uni), l2  * sizeof (unichar));
4072             h[l1 + l2] = 0;
4073             (yyval.uni) = h;
4074           }
4075     break;
4076
4077   case 232:
4078 #line 1711 "rcparse.y"
4079     {
4080             (yyval.uni) = unichar_dup ((yyvsp[(1) - (1)].uni));
4081           }
4082     break;
4083
4084   case 233:
4085 #line 1715 "rcparse.y"
4086     {
4087             unichar *h = NULL;
4088             unicode_from_ascii ((rc_uint_type *) NULL, &h, (yyvsp[(1) - (1)].s));
4089             (yyval.uni) = h;
4090           }
4091     break;
4092
4093   case 234:
4094 #line 1724 "rcparse.y"
4095     {
4096             (yyval.suni) = (yyvsp[(1) - (1)].suni);
4097           }
4098     break;
4099
4100   case 235:
4101 #line 1728 "rcparse.y"
4102     {
4103             unichar *h = NULL;
4104             rc_uint_type l = 0;
4105             unicode_from_ascii_len (&l, &h, (yyvsp[(1) - (1)].ss).s, (yyvsp[(1) - (1)].ss).length);
4106             (yyval.suni).s = h;
4107             (yyval.suni).length = l;
4108           }
4109     break;
4110
4111   case 236:
4112 #line 1740 "rcparse.y"
4113     {
4114             (yyval.suni) = (yyvsp[(1) - (1)].suni);
4115           }
4116     break;
4117
4118   case 237:
4119 #line 1745 "rcparse.y"
4120     {
4121             rc_uint_type l1 = (yyvsp[(1) - (2)].suni).length;
4122             rc_uint_type l2 = (yyvsp[(2) - (2)].suni).length;
4123             unichar *h = (unichar *) res_alloc ((l1 + l2 + 1) * sizeof (unichar));
4124             if (l1 != 0)
4125               memcpy (h, (yyvsp[(1) - (2)].suni).s, l1 * sizeof (unichar));
4126             if (l2 != 0)
4127               memcpy (h + l1, (yyvsp[(2) - (2)].suni).s, l2  * sizeof (unichar));
4128             h[l1 + l2] = 0;
4129             (yyval.suni).length = l1 + l2;
4130             (yyval.suni).s = h;
4131           }
4132     break;
4133
4134   case 238:
4135 #line 1761 "rcparse.y"
4136     {
4137             (yyval.ss) = (yyvsp[(1) - (1)].ss);
4138           }
4139     break;
4140
4141   case 239:
4142 #line 1765 "rcparse.y"
4143     {
4144             rc_uint_type l = (yyvsp[(1) - (2)].ss).length + (yyvsp[(2) - (2)].ss).length;
4145             char *h = (char *) res_alloc (l);
4146             memcpy (h, (yyvsp[(1) - (2)].ss).s, (yyvsp[(1) - (2)].ss).length);
4147             memcpy (h + (yyvsp[(1) - (2)].ss).length, (yyvsp[(2) - (2)].ss).s, (yyvsp[(2) - (2)].ss).length);
4148             (yyval.ss).s = h;
4149             (yyval.ss).length = l;
4150           }
4151     break;
4152
4153   case 240:
4154 #line 1777 "rcparse.y"
4155     {
4156             (yyval.suni) = (yyvsp[(1) - (1)].suni);
4157           }
4158     break;
4159
4160   case 241:
4161 #line 1781 "rcparse.y"
4162     {
4163             rc_uint_type l = (yyvsp[(1) - (2)].suni).length + (yyvsp[(2) - (2)].suni).length;
4164             unichar *h = (unichar *) res_alloc (l * sizeof (unichar));
4165             memcpy (h, (yyvsp[(1) - (2)].suni).s, (yyvsp[(1) - (2)].suni).length * sizeof (unichar));
4166             memcpy (h + (yyvsp[(1) - (2)].suni).length, (yyvsp[(2) - (2)].suni).s, (yyvsp[(2) - (2)].suni).length  * sizeof (unichar));
4167             (yyval.suni).s = h;
4168             (yyval.suni).length = l;
4169           }
4170     break;
4171
4172   case 242:
4173 #line 1803 "rcparse.y"
4174     {
4175             style |= (yyvsp[(1) - (1)].il);
4176           }
4177     break;
4178
4179   case 243:
4180 #line 1807 "rcparse.y"
4181     {
4182             style &=~ (yyvsp[(2) - (2)].il);
4183           }
4184     break;
4185
4186   case 244:
4187 #line 1811 "rcparse.y"
4188     {
4189             style |= (yyvsp[(3) - (3)].il);
4190           }
4191     break;
4192
4193   case 245:
4194 #line 1815 "rcparse.y"
4195     {
4196             style &=~ (yyvsp[(4) - (4)].il);
4197           }
4198     break;
4199
4200   case 246:
4201 #line 1822 "rcparse.y"
4202     {
4203             (yyval.il) = (yyvsp[(1) - (1)].i).val;
4204           }
4205     break;
4206
4207   case 247:
4208 #line 1826 "rcparse.y"
4209     {
4210             (yyval.il) = (yyvsp[(2) - (3)].il);
4211           }
4212     break;
4213
4214   case 248:
4215 #line 1835 "rcparse.y"
4216     {
4217             (yyval.il) = 0;
4218           }
4219     break;
4220
4221   case 249:
4222 #line 1839 "rcparse.y"
4223     {
4224             (yyval.il) = (yyvsp[(1) - (1)].il);
4225           }
4226     break;
4227
4228   case 250:
4229 #line 1848 "rcparse.y"
4230     {
4231             (yyval.il) = (yyvsp[(2) - (2)].il);
4232           }
4233     break;
4234
4235   case 251:
4236 #line 1857 "rcparse.y"
4237     {
4238             (yyval.il) = (yyvsp[(1) - (1)].i).val;
4239           }
4240     break;
4241
4242   case 252:
4243 #line 1866 "rcparse.y"
4244     {
4245             (yyval.i) = (yyvsp[(1) - (1)].i);
4246           }
4247     break;
4248
4249   case 253:
4250 #line 1870 "rcparse.y"
4251     {
4252             (yyval.i) = (yyvsp[(2) - (3)].i);
4253           }
4254     break;
4255
4256   case 254:
4257 #line 1874 "rcparse.y"
4258     {
4259             (yyval.i).val = ~ (yyvsp[(2) - (2)].i).val;
4260             (yyval.i).dword = (yyvsp[(2) - (2)].i).dword;
4261           }
4262     break;
4263
4264   case 255:
4265 #line 1879 "rcparse.y"
4266     {
4267             (yyval.i).val = - (yyvsp[(2) - (2)].i).val;
4268             (yyval.i).dword = (yyvsp[(2) - (2)].i).dword;
4269           }
4270     break;
4271
4272   case 256:
4273 #line 1884 "rcparse.y"
4274     {
4275             (yyval.i).val = (yyvsp[(1) - (3)].i).val * (yyvsp[(3) - (3)].i).val;
4276             (yyval.i).dword = (yyvsp[(1) - (3)].i).dword || (yyvsp[(3) - (3)].i).dword;
4277           }
4278     break;
4279
4280   case 257:
4281 #line 1889 "rcparse.y"
4282     {
4283             (yyval.i).val = (yyvsp[(1) - (3)].i).val / (yyvsp[(3) - (3)].i).val;
4284             (yyval.i).dword = (yyvsp[(1) - (3)].i).dword || (yyvsp[(3) - (3)].i).dword;
4285           }
4286     break;
4287
4288   case 258:
4289 #line 1894 "rcparse.y"
4290     {
4291             (yyval.i).val = (yyvsp[(1) - (3)].i).val % (yyvsp[(3) - (3)].i).val;
4292             (yyval.i).dword = (yyvsp[(1) - (3)].i).dword || (yyvsp[(3) - (3)].i).dword;
4293           }
4294     break;
4295
4296   case 259:
4297 #line 1899 "rcparse.y"
4298     {
4299             (yyval.i).val = (yyvsp[(1) - (3)].i).val + (yyvsp[(3) - (3)].i).val;
4300             (yyval.i).dword = (yyvsp[(1) - (3)].i).dword || (yyvsp[(3) - (3)].i).dword;
4301           }
4302     break;
4303
4304   case 260:
4305 #line 1904 "rcparse.y"
4306     {
4307             (yyval.i).val = (yyvsp[(1) - (3)].i).val - (yyvsp[(3) - (3)].i).val;
4308             (yyval.i).dword = (yyvsp[(1) - (3)].i).dword || (yyvsp[(3) - (3)].i).dword;
4309           }
4310     break;
4311
4312   case 261:
4313 #line 1909 "rcparse.y"
4314     {
4315             (yyval.i).val = (yyvsp[(1) - (3)].i).val & (yyvsp[(3) - (3)].i).val;
4316             (yyval.i).dword = (yyvsp[(1) - (3)].i).dword || (yyvsp[(3) - (3)].i).dword;
4317           }
4318     break;
4319
4320   case 262:
4321 #line 1914 "rcparse.y"
4322     {
4323             (yyval.i).val = (yyvsp[(1) - (3)].i).val ^ (yyvsp[(3) - (3)].i).val;
4324             (yyval.i).dword = (yyvsp[(1) - (3)].i).dword || (yyvsp[(3) - (3)].i).dword;
4325           }
4326     break;
4327
4328   case 263:
4329 #line 1919 "rcparse.y"
4330     {
4331             (yyval.i).val = (yyvsp[(1) - (3)].i).val | (yyvsp[(3) - (3)].i).val;
4332             (yyval.i).dword = (yyvsp[(1) - (3)].i).dword || (yyvsp[(3) - (3)].i).dword;
4333           }
4334     break;
4335
4336   case 264:
4337 #line 1930 "rcparse.y"
4338     {
4339             (yyval.il) = (yyvsp[(2) - (2)].il);
4340           }
4341     break;
4342
4343   case 265:
4344 #line 1939 "rcparse.y"
4345     {
4346             (yyval.il) = (yyvsp[(1) - (1)].i).val;
4347           }
4348     break;
4349
4350   case 266:
4351 #line 1950 "rcparse.y"
4352     {
4353             (yyval.i) = (yyvsp[(1) - (1)].i);
4354           }
4355     break;
4356
4357   case 267:
4358 #line 1954 "rcparse.y"
4359     {
4360             (yyval.i) = (yyvsp[(2) - (3)].i);
4361           }
4362     break;
4363
4364   case 268:
4365 #line 1958 "rcparse.y"
4366     {
4367             (yyval.i).val = ~ (yyvsp[(2) - (2)].i).val;
4368             (yyval.i).dword = (yyvsp[(2) - (2)].i).dword;
4369           }
4370     break;
4371
4372   case 269:
4373 #line 1963 "rcparse.y"
4374     {
4375             (yyval.i).val = (yyvsp[(1) - (3)].i).val * (yyvsp[(3) - (3)].i).val;
4376             (yyval.i).dword = (yyvsp[(1) - (3)].i).dword || (yyvsp[(3) - (3)].i).dword;
4377           }
4378     break;
4379
4380   case 270:
4381 #line 1968 "rcparse.y"
4382     {
4383             (yyval.i).val = (yyvsp[(1) - (3)].i).val / (yyvsp[(3) - (3)].i).val;
4384             (yyval.i).dword = (yyvsp[(1) - (3)].i).dword || (yyvsp[(3) - (3)].i).dword;
4385           }
4386     break;
4387
4388   case 271:
4389 #line 1973 "rcparse.y"
4390     {
4391             (yyval.i).val = (yyvsp[(1) - (3)].i).val % (yyvsp[(3) - (3)].i).val;
4392             (yyval.i).dword = (yyvsp[(1) - (3)].i).dword || (yyvsp[(3) - (3)].i).dword;
4393           }
4394     break;
4395
4396   case 272:
4397 #line 1978 "rcparse.y"
4398     {
4399             (yyval.i).val = (yyvsp[(1) - (3)].i).val + (yyvsp[(3) - (3)].i).val;
4400             (yyval.i).dword = (yyvsp[(1) - (3)].i).dword || (yyvsp[(3) - (3)].i).dword;
4401           }
4402     break;
4403
4404   case 273:
4405 #line 1983 "rcparse.y"
4406     {
4407             (yyval.i).val = (yyvsp[(1) - (3)].i).val - (yyvsp[(3) - (3)].i).val;
4408             (yyval.i).dword = (yyvsp[(1) - (3)].i).dword || (yyvsp[(3) - (3)].i).dword;
4409           }
4410     break;
4411
4412   case 274:
4413 #line 1988 "rcparse.y"
4414     {
4415             (yyval.i).val = (yyvsp[(1) - (3)].i).val & (yyvsp[(3) - (3)].i).val;
4416             (yyval.i).dword = (yyvsp[(1) - (3)].i).dword || (yyvsp[(3) - (3)].i).dword;
4417           }
4418     break;
4419
4420   case 275:
4421 #line 1993 "rcparse.y"
4422     {
4423             (yyval.i).val = (yyvsp[(1) - (3)].i).val ^ (yyvsp[(3) - (3)].i).val;
4424             (yyval.i).dword = (yyvsp[(1) - (3)].i).dword || (yyvsp[(3) - (3)].i).dword;
4425           }
4426     break;
4427
4428   case 276:
4429 #line 1998 "rcparse.y"
4430     {
4431             (yyval.i).val = (yyvsp[(1) - (3)].i).val | (yyvsp[(3) - (3)].i).val;
4432             (yyval.i).dword = (yyvsp[(1) - (3)].i).dword || (yyvsp[(3) - (3)].i).dword;
4433           }
4434     break;
4435
4436
4437 /* Line 1267 of yacc.c.  */
4438 #line 4439 "rcparse.c"
4439       default: break;
4440     }
4441   YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc);
4442
4443   YYPOPSTACK (yylen);
4444   yylen = 0;
4445   YY_STACK_PRINT (yyss, yyssp);
4446
4447   *++yyvsp = yyval;
4448
4449
4450   /* Now `shift' the result of the reduction.  Determine what state
4451      that goes to, based on the state we popped back to and the rule
4452      number reduced by.  */
4453
4454   yyn = yyr1[yyn];
4455
4456   yystate = yypgoto[yyn - YYNTOKENS] + *yyssp;
4457   if (0 <= yystate && yystate <= YYLAST && yycheck[yystate] == *yyssp)
4458     yystate = yytable[yystate];
4459   else
4460     yystate = yydefgoto[yyn - YYNTOKENS];
4461
4462   goto yynewstate;
4463
4464
4465 /*------------------------------------.
4466 | yyerrlab -- here on detecting error |
4467 `------------------------------------*/
4468 yyerrlab:
4469   /* If not already recovering from an error, report this error.  */
4470   if (!yyerrstatus)
4471     {
4472       ++yynerrs;
4473 #if ! YYERROR_VERBOSE
4474       yyerror (YY_("syntax error"));
4475 #else
4476       {
4477         YYSIZE_T yysize = yysyntax_error (0, yystate, yychar);
4478         if (yymsg_alloc < yysize && yymsg_alloc < YYSTACK_ALLOC_MAXIMUM)
4479           {
4480             YYSIZE_T yyalloc = 2 * yysize;
4481             if (! (yysize <= yyalloc && yyalloc <= YYSTACK_ALLOC_MAXIMUM))
4482               yyalloc = YYSTACK_ALLOC_MAXIMUM;
4483             if (yymsg != yymsgbuf)
4484               YYSTACK_FREE (yymsg);
4485             yymsg = (char *) YYSTACK_ALLOC (yyalloc);
4486             if (yymsg)
4487               yymsg_alloc = yyalloc;
4488             else
4489               {
4490                 yymsg = yymsgbuf;
4491                 yymsg_alloc = sizeof yymsgbuf;
4492               }
4493           }
4494
4495         if (0 < yysize && yysize <= yymsg_alloc)
4496           {
4497             (void) yysyntax_error (yymsg, yystate, yychar);
4498             yyerror (yymsg);
4499           }
4500         else
4501           {
4502             yyerror (YY_("syntax error"));
4503             if (yysize != 0)
4504               goto yyexhaustedlab;
4505           }
4506       }
4507 #endif
4508     }
4509
4510
4511
4512   if (yyerrstatus == 3)
4513     {
4514       /* If just tried and failed to reuse look-ahead token after an
4515          error, discard it.  */
4516
4517       if (yychar <= YYEOF)
4518         {
4519           /* Return failure if at end of input.  */
4520           if (yychar == YYEOF)
4521             YYABORT;
4522         }
4523       else
4524         {
4525           yydestruct ("Error: discarding",
4526                       yytoken, &yylval);
4527           yychar = YYEMPTY;
4528         }
4529     }
4530
4531   /* Else will try to reuse look-ahead token after shifting the error
4532      token.  */
4533   goto yyerrlab1;
4534
4535
4536 /*---------------------------------------------------.
4537 | yyerrorlab -- error raised explicitly by YYERROR.  |
4538 `---------------------------------------------------*/
4539 yyerrorlab:
4540
4541   /* Pacify compilers like GCC when the user code never invokes
4542      YYERROR and the label yyerrorlab therefore never appears in user
4543      code.  */
4544   if (/*CONSTCOND*/ 0)
4545      goto yyerrorlab;
4546
4547   /* Do not reclaim the symbols of the rule which action triggered
4548      this YYERROR.  */
4549   YYPOPSTACK (yylen);
4550   yylen = 0;
4551   YY_STACK_PRINT (yyss, yyssp);
4552   yystate = *yyssp;
4553   goto yyerrlab1;
4554
4555
4556 /*-------------------------------------------------------------.
4557 | yyerrlab1 -- common code for both syntax error and YYERROR.  |
4558 `-------------------------------------------------------------*/
4559 yyerrlab1:
4560   yyerrstatus = 3;      /* Each real token shifted decrements this.  */
4561
4562   for (;;)
4563     {
4564       yyn = yypact[yystate];
4565       if (yyn != YYPACT_NINF)
4566         {
4567           yyn += YYTERROR;
4568           if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYTERROR)
4569             {
4570               yyn = yytable[yyn];
4571               if (0 < yyn)
4572                 break;
4573             }
4574         }
4575
4576       /* Pop the current state because it cannot handle the error token.  */
4577       if (yyssp == yyss)
4578         YYABORT;
4579
4580
4581       yydestruct ("Error: popping",
4582                   yystos[yystate], yyvsp);
4583       YYPOPSTACK (1);
4584       yystate = *yyssp;
4585       YY_STACK_PRINT (yyss, yyssp);
4586     }
4587
4588   if (yyn == YYFINAL)
4589     YYACCEPT;
4590
4591   *++yyvsp = yylval;
4592
4593
4594   /* Shift the error token.  */
4595   YY_SYMBOL_PRINT ("Shifting", yystos[yyn], yyvsp, yylsp);
4596
4597   yystate = yyn;
4598   goto yynewstate;
4599
4600
4601 /*-------------------------------------.
4602 | yyacceptlab -- YYACCEPT comes here.  |
4603 `-------------------------------------*/
4604 yyacceptlab:
4605   yyresult = 0;
4606   goto yyreturn;
4607
4608 /*-----------------------------------.
4609 | yyabortlab -- YYABORT comes here.  |
4610 `-----------------------------------*/
4611 yyabortlab:
4612   yyresult = 1;
4613   goto yyreturn;
4614
4615 #ifndef yyoverflow
4616 /*-------------------------------------------------.
4617 | yyexhaustedlab -- memory exhaustion comes here.  |
4618 `-------------------------------------------------*/
4619 yyexhaustedlab:
4620   yyerror (YY_("memory exhausted"));
4621   yyresult = 2;
4622   /* Fall through.  */
4623 #endif
4624
4625 yyreturn:
4626   if (yychar != YYEOF && yychar != YYEMPTY)
4627      yydestruct ("Cleanup: discarding lookahead",
4628                  yytoken, &yylval);
4629   /* Do not reclaim the symbols of the rule which action triggered
4630      this YYABORT or YYACCEPT.  */
4631   YYPOPSTACK (yylen);
4632   YY_STACK_PRINT (yyss, yyssp);
4633   while (yyssp != yyss)
4634     {
4635       yydestruct ("Cleanup: popping",
4636                   yystos[*yyssp], yyvsp);
4637       YYPOPSTACK (1);
4638     }
4639 #ifndef yyoverflow
4640   if (yyss != yyssa)
4641     YYSTACK_FREE (yyss);
4642 #endif
4643 #if YYERROR_VERBOSE
4644   if (yymsg != yymsgbuf)
4645     YYSTACK_FREE (yymsg);
4646 #endif
4647   /* Make sure YYID is used.  */
4648   return YYID (yyresult);
4649 }
4650
4651
4652 #line 2004 "rcparse.y"
4653
4654
4655 /* Set the language from the command line.  */
4656
4657 void
4658 rcparse_set_language (int lang)
4659 {
4660   language = lang;
4661 }
4662