--- trunk/reactos/tools/wrc/y.tab.c 2005-10-08 00:41:31 UTC (rev 18319)
+++ trunk/reactos/tools/wrc/parser.tab.c 2005-10-08 12:43:38 UTC (rev 18327)
@@ -0,0 +1,5593 @@
+/* A Bison parser, made by GNU Bison 1.875c. */
+
+/* Skeleton parser for Yacc-like parsing with Bison,
+ Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2, or (at your option)
+ any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
+
+/* As a special exception, when this file is copied by Bison into a
+ Bison output file, you may use that output file without restriction.
+ This special exception was added by the Free Software Foundation
+ in version 1.24 of Bison. */
+
+/* Written by Richard Stallman by simplifying the original so called
+ ``semantic'' parser. */
+
+/* All symbols defined below should begin with yy or YY, to avoid
+ infringing on user name space. This should be done even for local
+ variables, as they might otherwise be expanded by user macros.
+ There are some unavoidable exceptions within include files to
+ define necessary library symbols; they are noted "INFRINGES ON
+ USER NAME SPACE" below. */
+
+/* Identify Bison output. */
+#define YYBISON 1
+
+/* Skeleton name. */
+#define YYSKELETON_NAME "yacc.c"
+
+/* Pure parsers. */
+#define YYPURE 0
+
+/* Using locations. */
+#define YYLSP_NEEDED 0
+
+
+
+/* Tokens. */
+#ifndef YYTOKENTYPE
+# define YYTOKENTYPE
+ /* Put the tokens into the symbol table, so that GDB and other debuggers
+ know about them. */
+ enum yytokentype {
+ tNL = 258,
+ tNUMBER = 259,
+ tLNUMBER = 260,
+ tSTRING = 261,
+ tIDENT = 262,
+ tFILENAME = 263,
+ tRAWDATA = 264,
+ tACCELERATORS = 265,
+ tBITMAP = 266,
+ tCURSOR = 267,
+ tDIALOG = 268,
+ tDIALOGEX = 269,
+ tMENU = 270,
+ tMENUEX = 271,
+ tMESSAGETABLE = 272,
+ tRCDATA = 273,
+ tVERSIONINFO = 274,
+ tSTRINGTABLE = 275,
+ tFONT = 276,
+ tFONTDIR = 277,
+ tICON = 278,
+ tHTML = 279,
+ tAUTO3STATE = 280,
+ tAUTOCHECKBOX = 281,
+ tAUTORADIOBUTTON = 282,
+ tCHECKBOX = 283,
+ tDEFPUSHBUTTON = 284,
+ tPUSHBUTTON = 285,
+ tRADIOBUTTON = 286,
+ tSTATE3 = 287,
+ tGROUPBOX = 288,
+ tCOMBOBOX = 289,
+ tLISTBOX = 290,
+ tSCROLLBAR = 291,
+ tCONTROL = 292,
+ tEDITTEXT = 293,
+ tRTEXT = 294,
+ tCTEXT = 295,
+ tLTEXT = 296,
+ tBLOCK = 297,
+ tVALUE = 298,
+ tSHIFT = 299,
+ tALT = 300,
+ tASCII = 301,
+ tVIRTKEY = 302,
+ tGRAYED = 303,
+ tCHECKED = 304,
+ tINACTIVE = 305,
+ tNOINVERT = 306,
+ tPURE = 307,
+ tIMPURE = 308,
+ tDISCARDABLE = 309,
+ tLOADONCALL = 310,
+ tPRELOAD = 311,
+ tFIXED = 312,
+ tMOVEABLE = 313,
+ tCLASS = 314,
+ tCAPTION = 315,
+ tCHARACTERISTICS = 316,
+ tEXSTYLE = 317,
+ tSTYLE = 318,
+ tVERSION = 319,
+ tLANGUAGE = 320,
+ tFILEVERSION = 321,
+ tPRODUCTVERSION = 322,
+ tFILEFLAGSMASK = 323,
+ tFILEOS = 324,
+ tFILETYPE = 325,
+ tFILEFLAGS = 326,
+ tFILESUBTYPE = 327,
+ tMENUBARBREAK = 328,
+ tMENUBREAK = 329,
+ tMENUITEM = 330,
+ tPOPUP = 331,
+ tSEPARATOR = 332,
+ tHELP = 333,
+ tTOOLBAR = 334,
+ tBUTTON = 335,
+ tBEGIN = 336,
+ tEND = 337,
+ tDLGINIT = 338,
+ tNOT = 339,
+ pUPM = 340
+ };
+#endif
+#define tNL 258
+#define tNUMBER 259
+#define tLNUMBER 260
+#define tSTRING 261
+#define tIDENT 262
+#define tFILENAME 263
+#define tRAWDATA 264
+#define tACCELERATORS 265
+#define tBITMAP 266
+#define tCURSOR 267
+#define tDIALOG 268
+#define tDIALOGEX 269
+#define tMENU 270
+#define tMENUEX 271
+#define tMESSAGETABLE 272
+#define tRCDATA 273
+#define tVERSIONINFO 274
+#define tSTRINGTABLE 275
+#define tFONT 276
+#define tFONTDIR 277
+#define tICON 278
+#define tHTML 279
+#define tAUTO3STATE 280
+#define tAUTOCHECKBOX 281
+#define tAUTORADIOBUTTON 282
+#define tCHECKBOX 283
+#define tDEFPUSHBUTTON 284
+#define tPUSHBUTTON 285
+#define tRADIOBUTTON 286
+#define tSTATE3 287
+#define tGROUPBOX 288
+#define tCOMBOBOX 289
+#define tLISTBOX 290
+#define tSCROLLBAR 291
+#define tCONTROL 292
+#define tEDITTEXT 293
+#define tRTEXT 294
+#define tCTEXT 295
+#define tLTEXT 296
+#define tBLOCK 297
+#define tVALUE 298
+#define tSHIFT 299
+#define tALT 300
+#define tASCII 301
+#define tVIRTKEY 302
+#define tGRAYED 303
+#define tCHECKED 304
+#define tINACTIVE 305
+#define tNOINVERT 306
+#define tPURE 307
+#define tIMPURE 308
+#define tDISCARDABLE 309
+#define tLOADONCALL 310
+#define tPRELOAD 311
+#define tFIXED 312
+#define tMOVEABLE 313
+#define tCLASS 314
+#define tCAPTION 315
+#define tCHARACTERISTICS 316
+#define tEXSTYLE 317
+#define tSTYLE 318
+#define tVERSION 319
+#define tLANGUAGE 320
+#define tFILEVERSION 321
+#define tPRODUCTVERSION 322
+#define tFILEFLAGSMASK 323
+#define tFILEOS 324
+#define tFILETYPE 325
+#define tFILEFLAGS 326
+#define tFILESUBTYPE 327
+#define tMENUBARBREAK 328
+#define tMENUBREAK 329
+#define tMENUITEM 330
+#define tPOPUP 331
+#define tSEPARATOR 332
+#define tHELP 333
+#define tTOOLBAR 334
+#define tBUTTON 335
+#define tBEGIN 336
+#define tEND 337
+#define tDLGINIT 338
+#define tNOT 339
+#define pUPM 340
+
+
+
+
+/* Copy the first part of user declarations. */
+#line 1 "./parser.y"
+
+/*
+ * Copyright 1994 Martin von Loewis
+ * Copyright 1998-2000 Bertho A. Stultiens (BS)
+ * 1999 Juergen Schmied (JS)
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ *
+ * History:
+ * 24-Jul-2000 BS - Made a fix for broken Berkeley yacc on
+ * non-terminals (see cjunk rule).
+ * 21-May-2000 BS - Partial implementation of font resources.
+ * - Corrected language propagation for binary
+ * resources such as bitmaps, icons, cursors,
+ * userres and rcdata. The language is now
+ * correct in .res files.
+ * - Fixed reading the resource name as ident,
+ * so that it may overlap keywords.
+ * 20-May-2000 BS - Implemented animated cursors and icons
+ * resource types.
+ * 30-Apr-2000 BS - Reintegration into the wine-tree
+ * 14-Jan-2000 BS - Redid the usertype resources so that they
+ * are compatible.
+ * 02-Jan-2000 BS - Removed the preprocessor from the grammar
+ * except for the # command (line numbers).
+ *
+ * 06-Nov-1999 JS - see CHANGES
+ *
+ * 29-Dec-1998 AdH - Grammar and function extensions.
+ * grammar: TOOLBAR resources, Named ICONs in
+ * DIALOGS
+ * functions: semantic actions for the grammar
+ * changes, resource files can now be anywhere
+ * on the include path instead of just in the
+ * current directory
+ *
+ * 20-Jun-1998 BS - Fixed a bug in load_file() where the name was not
+ * printed out correctly.
+ *
+ * 17-Jun-1998 BS - Fixed a bug in CLASS statement parsing which should
+ * also accept a tSTRING as argument.
+ *
+ * 25-May-1998 BS - Found out that I need to support language, version
+ * and characteristics in inline resources (bitmap,
+ * cursor, etc) but they can also be specified with
+ * a filename. This renders my filename-scanning scheme
+ * worthless. Need to build newline parsing to solve
+ * this one.
+ * It will come with version 1.1.0 (sigh).
+ *
+ * 19-May-1998 BS - Started to build a builtin preprocessor
+ *
+ * 30-Apr-1998 BS - Redid the stringtable parsing/handling. My previous
+ * ideas had some serious flaws.
+ *
+ * 27-Apr-1998 BS - Removed a lot of dead comments and put it in a doc
+ * file.
+ *
+ * 21-Apr-1998 BS - Added correct behavior for cursors and icons.
+ * - This file is growing too big. It is time to strip
+ * things and put it in a support file.
+ *
+ * 19-Apr-1998 BS - Tagged the stringtable resource so that only one
+ * resource will be created. This because the table
+ * has a different layout than other resources. The
+ * table has to be sorted, and divided into smaller
+ * resource entries (see comment in source).
+ *
+ * 17-Apr-1998 BS - Almost all strings, including identifiers, are parsed
+ * as string_t which include unicode strings upon
+ * input.
+ * - Parser now emits a warning when compiling win32
+ * extensions in win16 mode.
+ *
+ * 16-Apr-1998 BS - Raw data elements are now *optionally* separated
+ * by commas. Read the comments in file sq2dq.l.
+ * - FIXME: there are instances in the source that rely
+ * on the fact that int==32bit and pointers are int size.
+ * - Fixed the conflict in menuex by changing a rule
+ * back into right recursion. See note in source.
+ * - UserType resources cannot have an expression as its
+ * typeclass. See note in source.
+ *
+ * 15-Apr-1998 BS - Changed all right recursion into left recursion to
+ * get reduction of the parsestack.
+ * This also helps communication between bison and flex.
+ * Main advantage is that the Empty rule gets reduced
+ * first, which is used to allocate/link things.
+ * It also added a shift/reduce conflict in the menuex
+ * handling, due to expression/option possibility,
+ * although not serious.
+ *
+ * 14-Apr-1998 BS - Redone almost the entire parser. We're not talking
+ * about making it more efficient, but readable (for me)
+ * and slightly easier to expand/change.
+ * This is done primarily by using more reduce states
+ * with many (intuitive) types for the various resource
+ * statements.
+ * - Added expression handling for all resources where a
+ * number is accepted (not only for win32). Also added
+ * multiply and division (not MS compatible, but handy).
+ * Unary minus introduced a shift/reduce conflict, but
+ * it is not serious.
+ *
+ * 13-Apr-1998 BS - Reordered a lot of things
+ * - Made the source more readable
+ * - Added Win32 resource definitions
+ * - Corrected syntax problems with an old yacc (;)
+ * - Added extra comment about grammar
+ */
+#include "config.h"
+#include "wine/port.h"
+
+#include <stdio.h>
+#include <stdlib.h>
+#include <stdarg.h>
+#include <assert.h>
+#include <ctype.h>
+#include <string.h>
+#ifdef HAVE_ALLOCA_H
+#include <alloca.h>
+#endif
+
+#include "wrc.h"
+#include "utils.h"
+#include "newstruc.h"
+#include "dumpres.h"
+#include "wine/wpp.h"
+#include "wine/unicode.h"
+#include "parser.h"
+#include "windef.h"
+#include "winbase.h"
+#include "wingdi.h"
+#include "winuser.h"
+
+#if defined(YYBYACC)
+ /* Berkeley yacc (byacc) doesn't seem to know about these */
+ /* Some *BSD supplied versions do define these though */
+# ifndef YYEMPTY
+# define YYEMPTY (-1) /* Empty lookahead value of yychar */
+# endif
+# ifndef YYLEX
+# define YYLEX yylex()
+# endif
+
+#elif defined(YYBISON)
+ /* Bison was used for original development */
+ /* #define YYEMPTY -2 */
+ /* #define YYLEX yylex() */
+
+#else
+ /* No yacc we know yet */
+# if !defined(YYEMPTY) || !defined(YYLEX)
+# error Yacc version/type unknown. This version needs to be verified for settings of YYEMPTY and YYLEX.
+# elif defined(__GNUC__) /* gcc defines the #warning directive */
+# warning Yacc version/type unknown. It defines YYEMPTY and YYLEX, but is not tested
+ /* #else we just take a chance that it works... */
+# endif
+#endif
+
+int want_nl = 0; /* Signal flex that we need the next newline */
+int want_id = 0; /* Signal flex that we need the next identifier */
+stringtable_t *tagstt; /* Stringtable tag.
+ * It is set while parsing a stringtable to one of
+ * the stringtables in the sttres list or a new one
+ * if the language was not parsed before.
+ */
+stringtable_t *sttres; /* Stringtable resources. This holds the list of
+ * stringtables with different lanuages
+ */
+static int dont_want_id = 0; /* See language parsing for details */
+
+/* Set to the current options of the currently scanning stringtable */
+static int *tagstt_memopt;
+static characts_t *tagstt_characts;
+static version_t *tagstt_version;
+
+static const char riff[4] = "RIFF"; /* RIFF file magic for animated cursor/icon */
+
+/* Prototypes of here defined functions */
+static event_t *get_event_head(event_t *p);
+static control_t *get_control_head(control_t *p);
+static ver_value_t *get_ver_value_head(ver_value_t *p);
+static ver_block_t *get_ver_block_head(ver_block_t *p);
+static resource_t *get_resource_head(resource_t *p);
+static menuex_item_t *get_itemex_head(menuex_item_t *p);
+static menu_item_t *get_item_head(menu_item_t *p);
+static raw_data_t *merge_raw_data_str(raw_data_t *r1, string_t *str);
+static raw_data_t *merge_raw_data_int(raw_data_t *r1, int i);
+static raw_data_t *merge_raw_data_long(raw_data_t *r1, int i);
+static raw_data_t *merge_raw_data(raw_data_t *r1, raw_data_t *r2);
+static raw_data_t *str2raw_data(string_t *str);
+static raw_data_t *int2raw_data(int i);
+static raw_data_t *long2raw_data(int i);
+static raw_data_t *load_file(string_t *name, language_t *lang);
+static itemex_opt_t *new_itemex_opt(int id, int type, int state, int helpid);
+static event_t *add_string_event(string_t *key, int id, int flags, event_t *prev);
+static event_t *add_event(int key, int id, int flags, event_t *prev);
+static dialogex_t *dialogex_version(version_t *v, dialogex_t *dlg);
+static dialogex_t *dialogex_characteristics(characts_t *c, dialogex_t *dlg);
+static dialogex_t *dialogex_language(language_t *l, dialogex_t *dlg);
+static dialogex_t *dialogex_menu(name_id_t *m, dialogex_t *dlg);
+static dialogex_t *dialogex_class(name_id_t *n, dialogex_t *dlg);
+static dialogex_t *dialogex_font(font_id_t *f, dialogex_t *dlg);
+static dialogex_t *dialogex_caption(string_t *s, dialogex_t *dlg);
+static dialogex_t *dialogex_exstyle(style_t *st, dialogex_t *dlg);
+static dialogex_t *dialogex_style(style_t *st, dialogex_t *dlg);
+static name_id_t *convert_ctlclass(name_id_t *cls);
+static control_t *ins_ctrl(int type, int special_style, control_t *ctrl, control_t *prev);
+static dialog_t *dialog_version(version_t *v, dialog_t *dlg);
+static dialog_t *dialog_characteristics(characts_t *c, dialog_t *dlg);
+static dialog_t *dialog_language(language_t *l, dialog_t *dlg);
+static dialog_t *dialog_menu(name_id_t *m, dialog_t *dlg);
+static dialog_t *dialog_class(name_id_t *n, dialog_t *dlg);
+static dialog_t *dialog_font(font_id_t *f, dialog_t *dlg);
+static dialog_t *dialog_caption(string_t *s, dialog_t *dlg);
+static dialog_t *dialog_exstyle(style_t * st, dialog_t *dlg);
+static dialog_t *dialog_style(style_t * st, dialog_t *dlg);
+static resource_t *build_stt_resources(stringtable_t *stthead);
+static stringtable_t *find_stringtable(lvc_t *lvc);
+static toolbar_item_t *ins_tlbr_button(toolbar_item_t *prev, toolbar_item_t *idrec);
+static toolbar_item_t *get_tlbr_buttons_head(toolbar_item_t *p, int *nitems);
+static string_t *make_filename(string_t *s);
+static resource_t *build_fontdirs(resource_t *tail);
+static resource_t *build_fontdir(resource_t **fnt, int nfnt);
+static int rsrcid_to_token(int lookahead);
+
+
+
+/* Enabling traces. */
+#ifndef YYDEBUG
+# define YYDEBUG 1
+#endif
+
+/* Enabling verbose error messages. */
+#ifdef YYERROR_VERBOSE
+# undef YYERROR_VERBOSE
+# define YYERROR_VERBOSE 1
+#else
+# define YYERROR_VERBOSE 0
+#endif
+
+#if ! defined (YYSTYPE) && ! defined (YYSTYPE_IS_DECLARED)
+#line 241 "./parser.y"
+typedef union YYSTYPE {
+ string_t *str;
+ int num;
+ int *iptr;
+ char *cptr;
+ resource_t *res;
+ accelerator_t *acc;
+ bitmap_t *bmp;
+ dialog_t *dlg;
+ dialogex_t *dlgex;
+ font_t *fnt;
+ fontdir_t *fnd;
+ menu_t *men;
+ menuex_t *menex;
+ html_t *html;
+ rcdata_t *rdt;
+ stringtable_t *stt;
+ stt_entry_t *stte;
+ user_t *usr;
+ messagetable_t *msg;
+ versioninfo_t *veri;
+ control_t *ctl;
+ name_id_t *nid;
+ font_id_t *fntid;
+ language_t *lan;
+ version_t *ver;
+ characts_t *chars;
+ event_t *event;
+ menu_item_t *menitm;
+ menuex_item_t *menexitm;
+ itemex_opt_t *exopt;
+ raw_data_t *raw;
+ lvc_t *lvc;
+ ver_value_t *val;
+ ver_block_t *blk;
+ ver_words_t *verw;
+ toolbar_t *tlbar;
+ toolbar_item_t *tlbarItems;
+ dlginit_t *dginit;
+ style_pair_t *styles;
+ style_t *style;
+ ani_any_t *ani;
+} YYSTYPE;
+/* Line 191 of yacc.c. */
+#line 531 "parser.tab.c"
+# define yystype YYSTYPE /* obsolescent; will be withdrawn */
+# define YYSTYPE_IS_DECLARED 1
+# define YYSTYPE_IS_TRIVIAL 1
+#endif
+
+
+
+/* Copy the second part of user declarations. */
+
+
+/* Line 214 of yacc.c. */
+#line 543 "parser.tab.c"
+
+#if ! defined (yyoverflow) || YYERROR_VERBOSE
+
+# ifndef YYFREE
+# define YYFREE free
+# endif
+# ifndef YYMALLOC
+# define YYMALLOC malloc
+# endif
+
+/* The parser invokes alloca or malloc; define the necessary symbols. */
+
+# ifdef YYSTACK_USE_ALLOCA
+# if YYSTACK_USE_ALLOCA
+# define YYSTACK_ALLOC alloca
+# endif
+# else
+# if defined (alloca) || defined (_ALLOCA_H)
+# define YYSTACK_ALLOC alloca
+# else
+# ifdef __GNUC__
+# define YYSTACK_ALLOC __builtin_alloca
+# endif
+# endif
+# endif
+
+# ifdef YYSTACK_ALLOC
+ /* Pacify GCC's `empty if-body' warning. */
+# define YYSTACK_FREE(Ptr) do { /* empty */; } while (0)
+# else
+# if defined (__STDC__) || defined (__cplusplus)
+# include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
+# define YYSIZE_T size_t
+# endif
+# define YYSTACK_ALLOC YYMALLOC
+# define YYSTACK_FREE YYFREE
+# endif
+#endif /* ! defined (yyoverflow) || YYERROR_VERBOSE */
+
+
+#if (! defined (yyoverflow) \
+ && (! defined (__cplusplus) \
+ || (defined (YYSTYPE_IS_TRIVIAL) && YYSTYPE_IS_TRIVIAL)))
+
+/* A type that is properly aligned for any stack member. */
+union yyalloc
+{
+ short yyss;
+ YYSTYPE yyvs;
+ };
+
+/* The size of the maximum gap between one aligned stack and the next. */
+# define YYSTACK_GAP_MAXIMUM (sizeof (union yyalloc) - 1)
+
+/* The size of an array large to enough to hold all stacks, each with
+ N elements. */
+# define YYSTACK_BYTES(N) \
+ ((N) * (sizeof (short) + sizeof (YYSTYPE)) \
+ + YYSTACK_GAP_MAXIMUM)
+
+/* Copy COUNT objects from FROM to TO. The source and destination do
+ not overlap. */
+# ifndef YYCOPY
+# if defined (__GNUC__) && 1 < __GNUC__
+# define YYCOPY(To, From, Count) \
+ __builtin_memcpy (To, From, (Count) * sizeof (*(From)))
+# else
+# define YYCOPY(To, From, Count) \
+ do \
+ { \
+ register YYSIZE_T yyi; \
+ for (yyi = 0; yyi < (Count); yyi++) \
+ (To)[yyi] = (From)[yyi]; \
+ } \
+ while (0)
+# endif
+# endif
+
+/* Relocate STACK from its old location to the new one. The
+ local variables YYSIZE and YYSTACKSIZE give the old and new number of
+ elements in the stack, and YYPTR gives the new location of the
+ stack. Advance YYPTR to a properly aligned location for the next
+ stack. */
+# define YYSTACK_RELOCATE(Stack) \
+ do \
+ { \
+ YYSIZE_T yynewbytes; \
+ YYCOPY (&yyptr->Stack, Stack, yysize); \
+ Stack = &yyptr->Stack; \
+ yynewbytes = yystacksize * sizeof (*Stack) + YYSTACK_GAP_MAXIMUM; \
+ yyptr += yynewbytes / sizeof (*yyptr); \
+ } \
+ while (0)
+
+#endif
+
+#if defined (__STDC__) || defined (__cplusplus)
+ typedef signed char yysigned_char;
+#else
+ typedef short yysigned_char;
+#endif
+
+/* YYFINAL -- State number of the termination state. */
+#define YYFINAL 3
+/* YYLAST -- Last index in YYTABLE. */
+#define YYLAST 713
+
+/* YYNTOKENS -- Number of terminals. */
+#define YYNTOKENS 97
+/* YYNNTS -- Number of nonterminals. */
+#define YYNNTS 84
+/* YYNRULES -- Number of rules. */
+#define YYNRULES 259
+/* YYNRULES -- Number of states. */
+#define YYNSTATES 575
+
+/* YYTRANSLATE(YYLEX) -- Bison symbol number corresponding to YYLEX. */
+#define YYUNDEFTOK 2
+#define YYMAXUTOK 340
+
+#define YYTRANSLATE(YYX) \
+ ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK)
+
+/* YYTRANSLATE[YYLEX] -- Bison symbol number corresponding to YYLEX. */
+static const unsigned char yytranslate[] =
+{
+ 0, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 86, 2,
+ 95, 96, 89, 87, 94, 88, 2, 90, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 85, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 84, 2, 91, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 1, 2, 3, 4,
+ 5, 6, 7, 8, 9, 10, 11, 12, 13, 14,
+ 15, 16, 17, 18, 19, 20, 21, 22, 23, 24,
+ 25, 26, 27, 28, 29, 30, 31, 32, 33, 34,
+ 35, 36, 37, 38, 39, 40, 41, 42, 43, 44,
+ 45, 46, 47, 48, 49, 50, 51, 52, 53, 54,
+ 55, 56, 57, 58, 59, 60, 61, 62, 63, 64,
+ 65, 66, 67, 68, 69, 70, 71, 72, 73, 74,
+ 75, 76, 77, 78, 79, 80, 81, 82, 83, 92,
+ 93
+};
+
+#if YYDEBUG
+/* YYPRHS[YYN] -- Index of the first RHS symbol of rule number YYN in
+ YYRHS. */
+static const unsigned short yyprhs[] =
+{
+ 0, 0, 3, 5, 6, 9, 12, 16, 20, 22,
+ 23, 29, 30, 32, 34, 36, 38, 40, 42, 44,
+ 46, 48, 50, 52, 54, 56, 58, 60, 62, 64,
+ 66, 68, 70, 72, 74, 76, 78, 82, 86, 90,
+ 94, 98, 102, 106, 110, 114, 118, 120, 122, 129,
+ 130, 136, 142, 143, 146, 148, 152, 154, 156, 158,
+ 160, 162, 164, 178, 179, 183, 187, 191, 194, 198,
+ 202, 205, 208, 211, 212, 216, 220, 224, 228, 232,
+ 236, 240, 244, 248, 252, 256, 260, 264, 268, 272,
+ 276, 280, 291, 304, 315, 316, 321, 328, 337, 355,
+ 371, 376, 377, 380, 385, 389, 393, 395, 398, 400,
+ 402, 417, 418, 422, 426, 430, 433, 436, 440, 444,
+ 447, 450, 453, 454, 458, 462, 466, 470, 474, 478,
+ 482, 486, 490, 494, 498, 502, 506, 510, 514, 518,
+ 522, 533, 553, 570, 585, 598, 599, 601, 602, 605,
+ 615, 616, 619, 624, 628, 629, 636, 640, 646, 647,
+ 651, 655, 659, 663, 667, 671, 676, 680, 681, 686,
+ 690, 696, 697, 700, 706, 713, 714, 717, 722, 729,
+ 738, 743, 747, 748, 753, 754, 756, 763, 764, 774,
+ 784, 788, 792, 796, 800, 804, 805, 808, 814, 815,
+ 818, 820, 825, 830, 832, 836, 846, 847, 851, 854,
+ 855, 858, 861, 863, 865, 867, 869, 871, 873, 875,
+ 876, 879, 882, 885, 890, 893, 896, 901, 903, 905,
+ 908, 910, 913, 915, 919, 923, 928, 932, 937, 941,
+ 943, 945, 946, 948, 950, 954, 958, 962, 966, 970,
+ 974, 978, 981, 984, 987, 991, 993, 995, 998, 1000
+};
+
+/* YYRHS -- A `-1'-separated list of the rules' RHS. */
+static const short yyrhs[] =
+{
+ 98, 0, -1, 99, -1, -1, 99, 100, -1, 99,
+ 3, -1, 177, 102, 105, -1, 7, 102, 105, -1,
+ 153, -1, -1, 65, 101, 177, 94, 177, -1, -1,
+ 177, -1, 7, -1, 103, -1, 6, -1, 118, -1,
+ 107, -1, 108, -1, 123, -1, 134, -1, 115, -1,
+ 110, -1, 111, -1, 109, -1, 144, -1, 148, -1,
+ 112, -1, 113, -1, 114, -1, 164, -1, 116, -1,
+ 157, -1, 8, -1, 7, -1, 6, -1, 11, 166,
+ 175, -1, 12, 166, 175, -1, 23, 166, 175, -1,
+ 21, 166, 175, -1, 22, 166, 175, -1, 17, 166,
+ 175, -1, 24, 166, 175, -1, 18, 166, 175, -1,
+ 83, 166, 175, -1, 117, 166, 175, -1, 4, -1,
+ 7, -1, 10, 166, 169, 81, 119, 82, -1, -1,
+ 119, 6, 94, 177, 120, -1, 119, 177, 94, 177,
+ 120, -1, -1, 94, 121, -1, 122, -1, 121, 94,
+ 122, -1, 51, -1, 44, -1, 37, -1, 45, -1,
+ 46, -1, 47, -1, 13, 166, 177, 94, 177, 94,
+ 177, 94, 177, 124, 81, 125, 82, -1, -1, 124,
+ 63, 132, -1, 124, 62, 132, -1, 124, 60, 6,
+ -1, 124, 130, -1, 124, 59, 104, -1, 124, 15,
+ 103, -1, 124, 170, -1, 124, 171, -1, 124, 172,
+ -1, -1, 125, 37, 129, -1, 125, 38, 127, -1,
+ 125, 35, 127, -1, 125, 34, 127, -1, 125, 36,
+ 127, -1, 125, 28, 126, -1, 125, 29, 126, -1,
+ 125, 33, 126, -1, 125, 30, 126, -1, 125, 31,
+ 126, -1, 125, 25, 126, -1, 125, 32, 126, -1,
+ 125, 26, 126, -1, 125, 27, 126, -1, 125, 41,
+ 126, -1, 125, 40, 126, -1, 125, 39, 126, -1,
+ 125, 23, 104, 156, 177, 94, 177, 94, 177, 128,
+ -1, 6, 156, 177, 94, 177, 94, 177, 94, 177,
+ 94, 177, 131, -1, 177, 94, 177, 94, 177, 94,
+ 177, 94, 177, 131, -1, -1, 94, 177, 94, 177,
+ -1, 94, 177, 94, 177, 94, 132, -1, 94, 177,
+ 94, 177, 94, 132, 94, 132, -1, 104, 156, 177,
+ 94, 133, 94, 132, 94, 177, 94, 177, 94, 177,
+ 94, 177, 94, 132, -1, 104, 156, 177, 94, 133,
+ 94, 132, 94, 177, 94, 177, 94, 177, 94, 177,
+ -1, 21, 177, 94, 6, -1, -1, 94, 132, -1,
+ 94, 132, 94, 132, -1, 132, 84, 132, -1, 95,
+ 132, 96, -1, 178, -1, 92, 178, -1, 177, -1,
+ 6, -1, 14, 166, 177, 94, 177, 94, 177, 94,
+ 177, 141, 135, 81, 136, 82, -1, -1, 135, 63,
+ 132, -1, 135, 62, 132, -1, 135, 60, 6, -1,
+ 135, 130, -1, 135, 142, -1, 135, 59, 104, -1,
+ 135, 15, 103, -1, 135, 170, -1, 135, 171, -1,
+ 135, 172, -1, -1, 136, 37, 137, -1, 136, 38,
+ 139, -1, 136, 35, 139, -1, 136, 34, 139, -1,
+ 136, 36, 139, -1, 136, 28, 138, -1, 136, 29,
+ 138, -1, 136, 33, 138, -1, 136, 30, 138, -1,
+ 136, 31, 138, -1, 136, 25, 138, -1, 136, 32,
+ 138, -1, 136, 26, 138, -1, 136, 27, 138, -1,
+ 136, 41, 138, -1, 136, 40, 138, -1, 136, 39,
+ 138, -1, 136, 23, 104, 156, 177, 94, 177, 94,
+ 177, 128, -1, 104, 156, 177, 94, 133, 94, 132,
+ 94, 177, 94, 177, 94, 177, 94, 177, 94, 132,
+ 141, 140, -1, 104, 156, 177, 94, 133, 94, 132,
+ 94, 177, 94, 177, 94, 177, 94, 177, 140, -1,
+ 6, 156, 177, 94, 177, 94, 177, 94, 177, 94,
+ 177, 131, 141, 140, -1, 177, 94, 177, 94, 177,
+ 94, 177, 94, 177, 131, 141, 140, -1, -1, 173,
+ -1, -1, 94, 177, -1, 21, 177, 94, 6, 94,
+ 177, 94, 177, 143, -1, -1, 94, 177, -1, 15,
+ 166, 169, 145, -1, 81, 146, 82, -1, -1, 146,
+ 75, 6, 156, 177, 147, -1, 146, 75, 77, -1,
+ 146, 76, 6, 147, 145, -1, -1, 156, 49, 147,
+ -1, 156, 48, 147, -1, 156, 78, 147, -1, 156,
+ 50, 147, -1, 156, 73, 147, -1, 156, 74, 147,
+ -1, 16, 166, 169, 149, -1, 81, 150, 82, -1,
+ -1, 150, 75, 6, 151, -1, 150, 75, 77, -1,
+ 150, 76, 6, 152, 149, -1, -1, 94, 177, -1,
+ 94, 176, 94, 176, 147, -1, 94, 176, 94, 176,
+ 94, 177, -1, -1, 94, 177, -1, 94, 176, 94,
+ 177, -1, 94, 176, 94, 176, 94, 177, -1, 94,
+ 176, 94, 176, 94, 176, 94, 177, -1, 154, 81,
+ 155, 82, -1, 20, 166, 169, -1, -1, 155, 177,
+ 156, 6, -1, -1, 94, -1, 19, 166, 158, 81,
+ 159, 82, -1, -1, 158, 66, 177, 94, 177, 94,
+ 177, 94, 177, -1, 158, 67, 177, 94, 177, 94,
+ 177, 94, 177, -1, 158, 71, 177, -1, 158, 68,
+ 177, -1, 158, 69, 177, -1, 158, 70, 177, -1,
+ 158, 72, 177, -1, -1, 159, 160, -1, 42, 6,
+ 81, 161, 82, -1, -1, 161, 162, -1, 160, -1,
+ 43, 6, 94, 6, -1, 43, 6, 94, 163, -1,
+ 177, -1, 163, 94, 177, -1, 79, 166, 177, 94,
+ 177, 169, 81, 165, 82, -1, -1, 165, 80, 177,
+ -1, 165, 77, -1, -1, 166, 167, -1, 166, 168,
+ -1, 56, -1, 58, -1, 54, -1, 52, -1, 55,
+ -1, 57, -1, 53, -1, -1, 169, 170, -1, 169,
+ 171, -1, 169, 172, -1, 65, 177, 94, 177, -1,
+ 61, 177, -1, 64, 177, -1, 169, 81, 174, 82,
+ -1, 9, -1, 4, -1, 88, 4, -1, 5, -1,
+ 88, 5, -1, 6, -1, 174, 156, 9, -1, 174,
+ 156, 4, -1, 174, 156, 88, 4, -1, 174, 156,
+ 5, -1, 174, 156, 88, 5, -1, 174, 156, 6,
+ -1, 106, -1, 173, -1, -1, 177, -1, 179, -1,
+ 179, 87, 179, -1, 179, 88, 179, -1, 179, 84,
+ 179, -1, 179, 86, 179, -1, 179, 89, 179, -1,
+ 179, 90, 179, -1, 179, 85, 179, -1, 91, 179,
+ -1, 88, 179, -1, 87, 179, -1, 95, 179, 96,
+ -1, 180, -1, 178, -1, 92, 180, -1, 4, -1,
+ 5, -1
+};
+
+/* YYRLINE[YYN] -- source line where rule number YYN was defined. */
+static const unsigned short yyrline[] =
+{
+ 0, 364, 364, 398, 399, 469, 475, 487, 497, 505,
+ 505, 549, 555, 562, 572, 573, 582, 583, 584, 608,
+ 609, 615, 616, 617, 618, 642, 643, 649, 650, 651,
+ 652, 653, 654, 658, 659, 660, 664, 668, 684, 706,
+ 716, 724, 732, 736, 740, 744, 755, 760, 769, 793,
+ 794, 795, 804, 805, 808, 809, 812, 813, 814, 815,
+ 816, 817, 822, 857, 858, 859, 860, 861, 862, 863,
+ 864, 865, 866, 869, 870, 871, 872, 873, 874, 875,
+ 876, 877, 878, 880, 881, 882, 883, 884, 885, 886,
+ 887, 889, 899, 924, 946, 948, 953, 960, 971, 985,
+ 1000, 1005, 1006, 1007, 1011, 1012, 1013, 1014, 1018, 1023,
+ 1031, 1075, 1076, 1077, 1078, 1079, 1080, 1081, 1082, 1083,
+ 1084, 1085, 1088, 1089, 1090, 1091, 1092, 1093, 1094, 1095,
+ 1096, 1097, 1099, 1100, 1101, 1102, 1103, 1104, 1105, 1106,
+ 1108, 1118, 1143, 1159, 1187, 1210, 1211, 1214, 1215, 1219,
+ 1226, 1227, 1231, 1254, 1258, 1259, 1268, 1274, 1293, 1294,
+ 1295, 1296, 1297, 1298, 1299, 1303, 1328, 1332, 1333, 1349,
+ 1355, 1375, 1376, 1380, 1388, 1399, 1400, 1404, 1410, 1418,
+ 1438, 1479, 1490, 1491, 1524, 1526, 1531, 1547, 1548, 1558,
+ 1568, 1575, 1582, 1589, 1596, 1606, 1607, 1616, 1624, 1625,
+ 1634, 1639, 1645, 1654, 1655, 1659, 1685, 1686, 1691, 1700,
+ 1701, 1711, 1726, 1727, 1728, 1729, 1732, 1733, 1734, 1738,
+ 1739, 1747, 1755, 1773, 1780, 1784, 1788, 1803, 1804, 1805,
+ 1806, 1807, 1808, 1809, 1810, 1811, 1812, 1813, 1814, 1818,
+ 1819, 1826, 1827, 1831, 1834, 1835, 1836, 1837, 1838, 1839,
+ 1840, 1841, 1842, 1843, 1844, 1845, 1849, 1850, 1853, 1854
+};
+#endif
+
+#if YYDEBUG || YYERROR_VERBOSE
+/* YYTNME[SYMBOL-NUM] -- String name of the symbol SYMBOL-NUM.
+ First, the terminals, then, starting at YYNTOKENS, nonterminals. */
+static const char *const yytname[] =
+{
+ "$end", "error", "$undefined", "tNL", "tNUMBER", "tLNUMBER", "tSTRING",
+ "tIDENT", "tFILENAME", "tRAWDATA", "tACCELERATORS", "tBITMAP", "tCURSOR",
+ "tDIALOG", "tDIALOGEX", "tMENU", "tMENUEX", "tMESSAGETABLE", "tRCDATA",
+ "tVERSIONINFO", "tSTRINGTABLE", "tFONT", "tFONTDIR", "tICON", "tHTML",
+ "tAUTO3STATE", "tAUTOCHECKBOX", "tAUTORADIOBUTTON", "tCHECKBOX",
+ "tDEFPUSHBUTTON", "tPUSHBUTTON", "tRADIOBUTTON", "tSTATE3", "tGROUPBOX",
+ "tCOMBOBOX", "tLISTBOX", "tSCROLLBAR", "tCONTROL", "tEDITTEXT", "tRTEXT",
+ "tCTEXT", "tLTEXT", "tBLOCK", "tVALUE", "tSHIFT", "tALT", "tASCII",
+ "tVIRTKEY", "tGRAYED", "tCHECKED", "tINACTIVE", "tNOINVERT", "tPURE",
+ "tIMPURE", "tDISCARDABLE", "tLOADONCALL", "tPRELOAD", "tFIXED",
+ "tMOVEABLE", "tCLASS", "tCAPTION", "tCHARACTERISTICS", "tEXSTYLE",
+ "tSTYLE", "tVERSION", "tLANGUAGE", "tFILEVERSION", "tPRODUCTVERSION",
+ "tFILEFLAGSMASK", "tFILEOS", "tFILETYPE", "tFILEFLAGS", "tFILESUBTYPE",
+ "tMENUBARBREAK", "tMENUBREAK", "tMENUITEM", "tPOPUP", "tSEPARATOR",
+ "tHELP", "tTOOLBAR", "tBUTTON", "tBEGIN", "tEND", "tDLGINIT", "'|'",
+ "'^'", "'&'", "'+'", "'-'", "'*'", "'/'", "'~'", "tNOT", "pUPM", "','",
+ "'('", "')'", "$accept", "resource_file", "resources", "resource", "@1",
+ "usrcvt", "nameid", "nameid_s", "resource_definition", "filename",
+ "bitmap", "cursor", "icon", "font", "fontdir", "messagetable", "html",
+ "rcdata", "dlginit", "userres", "usertype", "accelerators", "events",
[truncated at 1000 lines; 10840 more skipped]