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