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