diff options
author | Eugene Sandulenko | 2017-01-06 18:17:30 +0100 |
---|---|---|
committer | Eugene Sandulenko | 2017-01-06 18:17:30 +0100 |
commit | dd60bb88d1117435363e605cca36abaa176214ab (patch) | |
tree | 9c86c9f384ba1e138568dd726c29f9315029d735 /engines/director | |
parent | 95733eca85e6b5fe13ff084ee134ca8815cf435a (diff) | |
download | scummvm-rg350-dd60bb88d1117435363e605cca36abaa176214ab.tar.gz scummvm-rg350-dd60bb88d1117435363e605cca36abaa176214ab.tar.bz2 scummvm-rg350-dd60bb88d1117435363e605cca36abaa176214ab.zip |
DIRECTOR: Lingo: Implement 'on' statement parsing
Diffstat (limited to 'engines/director')
-rw-r--r-- | engines/director/lingo/lingo-gr.cpp | 1028 | ||||
-rw-r--r-- | engines/director/lingo/lingo-gr.h | 8 | ||||
-rw-r--r-- | engines/director/lingo/lingo-gr.y | 14 | ||||
-rw-r--r-- | engines/director/lingo/lingo-lex.cpp | 600 | ||||
-rw-r--r-- | engines/director/lingo/lingo-lex.l | 2 |
5 files changed, 872 insertions, 780 deletions
diff --git a/engines/director/lingo/lingo-gr.cpp b/engines/director/lingo/lingo-gr.cpp index aef81fad8a..260c92a198 100644 --- a/engines/director/lingo/lingo-gr.cpp +++ b/engines/director/lingo/lingo-gr.cpp @@ -134,7 +134,9 @@ tSTARTS = 323, tSPRITE = 324, tINTERSECTS = 325, - tWITHIN = 326 + tWITHIN = 326, + tON = 327, + tME = 328 }; #endif /* Tokens. */ @@ -207,6 +209,8 @@ #define tSPRITE 324 #define tINTERSECTS 325 #define tWITHIN 326 +#define tON 327 +#define tME 328 @@ -264,7 +268,7 @@ typedef union YYSTYPE Common::Array<double> *arr; } /* Line 193 of yacc.c. */ -#line 268 "engines/director/lingo/lingo-gr.cpp" +#line 272 "engines/director/lingo/lingo-gr.cpp" YYSTYPE; # define yystype YYSTYPE /* obsolescent; will be withdrawn */ # define YYSTYPE_IS_DECLARED 1 @@ -277,7 +281,7 @@ typedef union YYSTYPE /* Line 216 of yacc.c. */ -#line 281 "engines/director/lingo/lingo-gr.cpp" +#line 285 "engines/director/lingo/lingo-gr.cpp" #ifdef short # undef short @@ -490,22 +494,22 @@ union yyalloc #endif /* YYFINAL -- State number of the termination state. */ -#define YYFINAL 92 +#define YYFINAL 94 /* YYLAST -- Last index in YYTABLE. */ -#define YYLAST 995 +#define YYLAST 1098 /* YYNTOKENS -- Number of terminals. */ -#define YYNTOKENS 85 +#define YYNTOKENS 87 /* YYNNTS -- Number of nonterminals. */ -#define YYNNTS 37 +#define YYNNTS 39 /* YYNRULES -- Number of rules. */ -#define YYNRULES 130 +#define YYNRULES 134 /* YYNRULES -- Number of states. */ -#define YYNSTATES 269 +#define YYNSTATES 282 /* YYTRANSLATE(YYLEX) -- Bison symbol number corresponding to YYLEX. */ #define YYUNDEFTOK 2 -#define YYMAXUTOK 326 +#define YYMAXUTOK 328 #define YYTRANSLATE(YYX) \ ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK) @@ -514,12 +518,12 @@ union yyalloc static const yytype_uint8 yytranslate[] = { 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 79, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 81, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 2, 2, 2, 78, 73, 2, - 80, 81, 76, 74, 84, 75, 2, 77, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 80, 75, 2, + 82, 83, 78, 76, 86, 77, 2, 79, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 83, 72, 82, 2, 2, 2, 2, 2, 2, 2, + 85, 74, 84, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, @@ -545,7 +549,7 @@ static const yytype_uint8 yytranslate[] = 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, - 65, 66, 67, 68, 69, 70, 71 + 65, 66, 67, 68, 69, 70, 71, 72, 73 }; #if YYDEBUG @@ -565,81 +569,83 @@ static const yytype_uint16 yyprhs[] = 353, 355, 358, 361, 364, 367, 369, 372, 377, 380, 382, 386, 388, 392, 395, 398, 401, 404, 408, 411, 414, 416, 420, 423, 426, 429, 433, 436, 437, 446, - 449, 450, 459, 460, 462, 466, 471, 472, 476, 477, - 479 + 449, 450, 459, 460, 468, 469, 478, 479, 481, 485, + 490, 491, 495, 496, 498 }; /* YYRHS -- A `-1'-separated list of the rules' RHS. */ static const yytype_int8 yyrhs[] = { - 86, 0, -1, 86, 87, 88, -1, 88, -1, 1, - 87, -1, 79, -1, -1, 115, -1, 108, -1, 120, - -1, 89, -1, 91, -1, 40, 107, 33, 21, -1, - 42, 21, 72, 107, -1, 42, 13, 72, 107, -1, - 42, 14, 107, 72, 107, -1, 42, 21, 44, 107, - -1, 42, 13, 44, 107, -1, 42, 14, 107, 44, - 107, -1, 107, -1, 108, -1, 90, -1, 92, -1, - 99, 80, 98, 81, 105, 104, 27, 41, -1, 100, - 72, 107, 104, 44, 107, 104, 105, 104, 27, 41, - -1, 100, 72, 107, 104, 24, 44, 107, 104, 105, - 104, 27, 41, -1, 106, 107, 104, -1, 101, 98, - 43, 87, 105, 104, 27, 32, -1, 101, 98, 43, - 87, 105, 104, 48, 105, 104, 27, 32, -1, 101, - 98, 43, 87, 105, 104, 103, 94, 104, 27, 32, - -1, 101, 98, 43, 103, 90, 104, -1, 101, 98, - 43, 103, 90, 104, 48, 103, 90, 104, -1, 101, - 98, 43, 103, 90, 104, 95, 104, 93, 104, -1, - -1, 48, 103, 90, -1, 94, 97, -1, 97, -1, - 95, 96, -1, 96, -1, 102, 98, 43, 103, 91, - 104, -1, 95, -1, 102, 98, 43, 105, 104, -1, - 107, -1, 107, 72, 107, -1, 80, 98, 81, -1, + 88, 0, -1, 88, 89, 90, -1, 90, -1, 1, + 89, -1, 81, -1, -1, 117, -1, 110, -1, 124, + -1, 91, -1, 93, -1, 40, 109, 33, 21, -1, + 42, 21, 74, 109, -1, 42, 13, 74, 109, -1, + 42, 14, 109, 74, 109, -1, 42, 21, 44, 109, + -1, 42, 13, 44, 109, -1, 42, 14, 109, 44, + 109, -1, 109, -1, 110, -1, 92, -1, 94, -1, + 101, 82, 100, 83, 107, 106, 27, 41, -1, 102, + 74, 109, 106, 44, 109, 106, 107, 106, 27, 41, + -1, 102, 74, 109, 106, 24, 44, 109, 106, 107, + 106, 27, 41, -1, 108, 109, 106, -1, 103, 100, + 43, 89, 107, 106, 27, 32, -1, 103, 100, 43, + 89, 107, 106, 48, 107, 106, 27, 32, -1, 103, + 100, 43, 89, 107, 106, 105, 96, 106, 27, 32, + -1, 103, 100, 43, 105, 92, 106, -1, 103, 100, + 43, 105, 92, 106, 48, 105, 92, 106, -1, 103, + 100, 43, 105, 92, 106, 97, 106, 95, 106, -1, + -1, 48, 105, 92, -1, 96, 99, -1, 99, -1, + 97, 98, -1, 98, -1, 104, 100, 43, 105, 93, + 106, -1, 97, -1, 104, 100, 43, 107, 106, -1, + 109, -1, 109, 74, 109, -1, 82, 100, 83, -1, 41, 47, -1, 41, 46, 21, -1, 32, -1, 26, - -1, -1, -1, -1, 105, 87, -1, 105, 91, -1, + -1, -1, -1, -1, 107, 89, -1, 107, 93, -1, 45, 21, 43, -1, 12, -1, 15, -1, 22, -1, - 17, -1, 21, 80, 121, 81, -1, 21, -1, 13, - -1, 14, 107, -1, 89, -1, 107, 74, 107, -1, - 107, 75, 107, -1, 107, 76, 107, -1, 107, 77, - 107, -1, 107, 65, 107, -1, 107, 82, 107, -1, - 107, 83, 107, -1, 107, 61, 107, -1, 107, 56, - 107, -1, 107, 57, 107, -1, 107, 62, 107, -1, - 107, 63, 107, -1, 64, 107, -1, 107, 73, 107, - -1, 107, 66, 107, -1, 107, 67, 107, -1, 107, - 68, 107, -1, 74, 107, -1, 75, 107, -1, 80, - 107, 81, -1, 69, 107, 70, 107, -1, 69, 107, - 71, 107, -1, 40, 107, -1, 111, -1, 114, -1, - 28, 41, -1, 28, -1, 30, 109, -1, 55, 110, - -1, 19, 107, -1, 18, 107, -1, 18, -1, 20, - 121, -1, 51, 107, 46, 107, -1, 51, 107, -1, - 21, -1, 109, 84, 21, -1, 21, -1, 110, 84, + 17, -1, 21, 82, 125, 83, -1, 21, -1, 13, + -1, 14, 109, -1, 91, -1, 109, 76, 109, -1, + 109, 77, 109, -1, 109, 78, 109, -1, 109, 79, + 109, -1, 109, 65, 109, -1, 109, 84, 109, -1, + 109, 85, 109, -1, 109, 61, 109, -1, 109, 56, + 109, -1, 109, 57, 109, -1, 109, 62, 109, -1, + 109, 63, 109, -1, 64, 109, -1, 109, 75, 109, + -1, 109, 66, 109, -1, 109, 67, 109, -1, 109, + 68, 109, -1, 76, 109, -1, 77, 109, -1, 82, + 109, 83, -1, 69, 109, 70, 109, -1, 69, 109, + 71, 109, -1, 40, 109, -1, 113, -1, 116, -1, + 28, 41, -1, 28, -1, 30, 111, -1, 55, 112, + -1, 19, 109, -1, 18, 109, -1, 18, -1, 20, + 125, -1, 51, 109, 46, 109, -1, 51, 109, -1, + 21, -1, 111, 86, 21, -1, 21, -1, 112, 86, 21, -1, 31, 34, -1, 31, 37, -1, 31, 39, - -1, 31, 112, -1, 31, 112, 113, -1, 31, 113, - -1, 29, 107, -1, 107, -1, 38, 36, 107, -1, - 36, 107, -1, 52, 53, -1, 52, 112, -1, 52, - 112, 113, -1, 52, 113, -1, -1, 35, 21, 116, - 103, 118, 87, 119, 105, -1, 49, 21, -1, -1, - 50, 21, 117, 103, 118, 87, 119, 105, -1, -1, - 21, -1, 118, 84, 21, -1, 118, 87, 84, 21, - -1, -1, 21, 103, 121, -1, -1, 107, -1, 121, - 84, 107, -1 + -1, 31, 114, -1, 31, 114, 115, -1, 31, 115, + -1, 29, 109, -1, 109, -1, 38, 36, 109, -1, + 36, 109, -1, 52, 53, -1, 52, 114, -1, 52, + 114, 115, -1, 52, 115, -1, -1, 35, 21, 118, + 105, 122, 89, 123, 107, -1, 49, 21, -1, -1, + 50, 21, 119, 105, 122, 89, 123, 107, -1, -1, + 72, 21, 120, 105, 89, 107, 27, -1, -1, 72, + 21, 121, 105, 73, 89, 107, 27, -1, -1, 21, + -1, 122, 86, 21, -1, 122, 89, 86, 21, -1, + -1, 21, 105, 125, -1, -1, 109, -1, 125, 86, + 109, -1 }; /* YYRLINE[YYN] -- source line where rule number YYN was defined. */ static const yytype_uint16 yyrline[] = { - 0, 105, 105, 106, 107, 110, 115, 116, 117, 118, - 119, 120, 123, 129, 135, 143, 151, 157, 165, 174, - 175, 177, 178, 183, 194, 210, 222, 230, 237, 246, - 255, 265, 275, 286, 287, 290, 291, 294, 295, 298, - 306, 307, 315, 316, 317, 319, 321, 327, 333, 340, - 342, 344, 345, 346, 349, 355, 356, 359, 362, 365, - 368, 372, 379, 385, 386, 387, 388, 389, 390, 391, - 392, 393, 394, 395, 396, 397, 398, 399, 400, 401, - 402, 403, 404, 405, 406, 407, 410, 411, 412, 413, - 414, 416, 417, 418, 421, 424, 427, 428, 429, 432, - 433, 436, 437, 448, 449, 450, 451, 454, 457, 462, - 463, 466, 467, 470, 471, 474, 477, 507, 507, 513, - 516, 516, 521, 522, 523, 524, 526, 530, 538, 539, - 540 + 0, 106, 106, 107, 108, 111, 116, 117, 118, 119, + 120, 121, 124, 130, 136, 144, 152, 158, 166, 175, + 176, 178, 179, 184, 195, 211, 223, 231, 238, 247, + 256, 266, 276, 287, 288, 291, 292, 295, 296, 299, + 307, 308, 316, 317, 318, 320, 322, 328, 334, 341, + 343, 345, 346, 347, 350, 356, 357, 360, 363, 366, + 369, 373, 380, 386, 387, 388, 389, 390, 391, 392, + 393, 394, 395, 396, 397, 398, 399, 400, 401, 402, + 403, 404, 405, 406, 407, 408, 411, 412, 413, 414, + 415, 417, 418, 419, 422, 425, 428, 429, 430, 433, + 434, 437, 438, 449, 450, 451, 452, 455, 458, 463, + 464, 467, 468, 471, 472, 475, 478, 508, 508, 514, + 517, 517, 522, 522, 528, 528, 535, 536, 537, 538, + 540, 544, 552, 553, 554 }; #endif @@ -658,15 +664,15 @@ static const char *const yytname[] = "tNLELSE", "tFACTORY", "tMETHOD", "tOPEN", "tPLAY", "tDONE", "tPLAYACCEL", "tINSTANCE", "tGE", "tLE", "tGT", "tLT", "tEQ", "tNEQ", "tAND", "tOR", "tNOT", "tMOD", "tCONCAT", "tCONTAINS", "tSTARTS", - "tSPRITE", "tINTERSECTS", "tWITHIN", "'='", "'&'", "'+'", "'-'", "'*'", - "'/'", "'%'", "'\\n'", "'('", "')'", "'>'", "'<'", "','", "$accept", - "program", "nl", "programline", "asgn", "stmtoneliner", "stmt", "ifstmt", - "elsestmtoneliner", "elseifstmt", "elseifstmtoneliner", + "tSPRITE", "tINTERSECTS", "tWITHIN", "tON", "tME", "'='", "'&'", "'+'", + "'-'", "'*'", "'/'", "'%'", "'\\n'", "'('", "')'", "'>'", "'<'", "','", + "$accept", "program", "nl", "programline", "asgn", "stmtoneliner", + "stmt", "ifstmt", "elsestmtoneliner", "elseifstmt", "elseifstmtoneliner", "elseifstmtoneliner1", "elseifstmt1", "cond", "repeatwhile", "repeatwith", "if", "elseif", "begin", "end", "stmtlist", "when", "expr", "func", "globallist", "instancelist", "gotofunc", "gotoframe", - "gotomovie", "playfunc", "defn", "@1", "@2", "argdef", "argstore", - "macro", "arglist", 0 + "gotomovie", "playfunc", "defn", "@1", "@2", "@3", "@4", "argdef", + "argstore", "macro", "arglist", 0 }; #endif @@ -682,28 +688,28 @@ static const yytype_uint16 yytoknum[] = 295, 296, 297, 298, 299, 300, 301, 302, 303, 304, 305, 306, 307, 308, 309, 310, 311, 312, 313, 314, 315, 316, 317, 318, 319, 320, 321, 322, 323, 324, - 325, 326, 61, 38, 43, 45, 42, 47, 37, 10, - 40, 41, 62, 60, 44 + 325, 326, 327, 328, 61, 38, 43, 45, 42, 47, + 37, 10, 40, 41, 62, 60, 44 }; # endif /* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */ static const yytype_uint8 yyr1[] = { - 0, 85, 86, 86, 86, 87, 88, 88, 88, 88, - 88, 88, 89, 89, 89, 89, 89, 89, 89, 90, - 90, 91, 91, 91, 91, 91, 91, 92, 92, 92, - 92, 92, 92, 93, 93, 94, 94, 95, 95, 96, - 97, 97, 98, 98, 98, 99, 100, 101, 102, 103, - 104, 105, 105, 105, 106, 107, 107, 107, 107, 107, - 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, - 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, - 107, 107, 107, 107, 107, 107, 108, 108, 108, 108, - 108, 108, 108, 108, 108, 108, 108, 108, 108, 109, - 109, 110, 110, 111, 111, 111, 111, 111, 111, 112, - 112, 113, 113, 114, 114, 114, 114, 116, 115, 115, - 117, 115, 118, 118, 118, 118, 119, 120, 121, 121, - 121 + 0, 87, 88, 88, 88, 89, 90, 90, 90, 90, + 90, 90, 91, 91, 91, 91, 91, 91, 91, 92, + 92, 93, 93, 93, 93, 93, 93, 94, 94, 94, + 94, 94, 94, 95, 95, 96, 96, 97, 97, 98, + 99, 99, 100, 100, 100, 101, 102, 103, 104, 105, + 106, 107, 107, 107, 108, 109, 109, 109, 109, 109, + 109, 109, 109, 109, 109, 109, 109, 109, 109, 109, + 109, 109, 109, 109, 109, 109, 109, 109, 109, 109, + 109, 109, 109, 109, 109, 109, 110, 110, 110, 110, + 110, 110, 110, 110, 110, 110, 110, 110, 110, 111, + 111, 112, 112, 113, 113, 113, 113, 113, 113, 114, + 114, 115, 115, 116, 116, 116, 116, 118, 117, 117, + 119, 117, 120, 117, 121, 117, 122, 122, 122, 122, + 123, 124, 125, 125, 125 }; /* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN. */ @@ -721,8 +727,8 @@ static const yytype_uint8 yyr2[] = 1, 2, 2, 2, 2, 1, 2, 4, 2, 1, 3, 1, 3, 2, 2, 2, 2, 3, 2, 2, 1, 3, 2, 2, 2, 3, 2, 0, 8, 2, - 0, 8, 0, 1, 3, 4, 0, 3, 0, 1, - 3 + 0, 8, 0, 7, 0, 8, 0, 1, 3, 4, + 0, 3, 0, 1, 3 }; /* YYDEFACT[STATE-NAME] -- Default rule to reduce with in state @@ -730,298 +736,322 @@ static const yytype_uint8 yyr2[] = means the default is an error. */ static const yytype_uint8 yydefact[] = { - 0, 0, 55, 61, 0, 56, 58, 95, 0, 128, + 0, 0, 55, 61, 0, 56, 58, 95, 0, 132, 49, 57, 90, 0, 0, 47, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 3, 63, 21, 11, 22, 0, 0, 0, - 0, 19, 8, 87, 88, 7, 9, 5, 4, 60, - 0, 63, 62, 94, 93, 129, 96, 128, 128, 89, - 99, 91, 0, 103, 0, 104, 0, 105, 110, 106, - 108, 117, 86, 0, 45, 0, 0, 0, 0, 119, - 120, 98, 113, 114, 116, 101, 92, 76, 0, 81, - 82, 0, 1, 6, 0, 0, 0, 0, 42, 50, + 0, 0, 0, 3, 63, 21, 11, 22, 0, 0, + 0, 0, 19, 8, 87, 88, 7, 9, 5, 4, + 60, 0, 63, 62, 94, 93, 133, 96, 132, 132, + 89, 99, 91, 0, 103, 0, 104, 0, 105, 110, + 106, 108, 117, 86, 0, 45, 0, 0, 0, 0, + 119, 120, 98, 113, 114, 116, 101, 92, 76, 0, + 122, 81, 82, 0, 1, 6, 0, 0, 0, 0, + 42, 50, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 127, - 0, 109, 112, 0, 107, 49, 0, 46, 0, 0, - 0, 0, 0, 54, 49, 0, 115, 0, 0, 0, - 83, 2, 0, 50, 0, 0, 49, 0, 26, 72, - 73, 71, 74, 75, 68, 78, 79, 80, 77, 64, - 65, 66, 67, 69, 70, 130, 59, 100, 111, 122, - 12, 17, 14, 0, 0, 16, 13, 122, 97, 102, - 84, 85, 51, 0, 44, 51, 0, 43, 123, 0, - 18, 15, 0, 50, 0, 0, 50, 50, 20, 0, - 126, 126, 52, 53, 0, 0, 50, 49, 30, 124, - 0, 51, 51, 0, 50, 51, 0, 51, 0, 48, - 49, 50, 38, 0, 125, 118, 121, 23, 51, 50, - 27, 50, 50, 40, 36, 0, 0, 37, 33, 0, - 50, 0, 0, 35, 0, 0, 50, 49, 50, 49, - 0, 0, 0, 0, 49, 31, 0, 32, 0, 0, - 24, 28, 29, 50, 34, 50, 25, 41, 39 + 0, 131, 0, 109, 112, 0, 107, 49, 0, 46, + 0, 0, 0, 0, 0, 54, 49, 0, 115, 0, + 0, 0, 49, 49, 83, 2, 0, 50, 0, 0, + 49, 0, 26, 72, 73, 71, 74, 75, 68, 78, + 79, 80, 77, 64, 65, 66, 67, 69, 70, 134, + 59, 100, 111, 126, 12, 17, 14, 0, 0, 16, + 13, 126, 97, 102, 84, 85, 0, 0, 51, 0, + 44, 51, 0, 43, 127, 0, 18, 15, 0, 51, + 0, 50, 0, 0, 50, 50, 20, 0, 130, 130, + 0, 51, 52, 53, 0, 0, 50, 49, 30, 128, + 0, 51, 51, 123, 0, 0, 50, 51, 0, 51, + 0, 48, 49, 50, 38, 0, 129, 118, 121, 125, + 23, 51, 50, 27, 50, 50, 40, 36, 0, 0, + 37, 33, 0, 50, 0, 0, 35, 0, 0, 50, + 49, 50, 49, 0, 0, 0, 0, 49, 31, 0, + 32, 0, 0, 24, 28, 29, 50, 34, 50, 25, + 41, 39 }; /* YYDEFGOTO[NTERM-NUM]. */ static const yytype_int16 yydefgoto[] = { - -1, 31, 202, 32, 51, 34, 203, 36, 248, 232, - 233, 222, 234, 97, 37, 38, 39, 223, 258, 148, - 193, 40, 41, 198, 61, 86, 43, 69, 70, 44, - 45, 125, 134, 189, 211, 46, 56 + -1, 32, 212, 33, 52, 35, 213, 37, 261, 245, + 246, 234, 247, 99, 38, 39, 40, 235, 271, 152, + 201, 41, 42, 206, 62, 87, 44, 70, 71, 45, + 46, 127, 136, 142, 143, 195, 221, 47, 57 }; /* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing STATE-NUM. */ -#define YYPACT_NINF -206 +#define YYPACT_NINF -214 static const yytype_int16 yypact[] = { - 263, -61, -206, -206, 671, -206, -206, 671, 671, 671, - 912, -206, -17, 9, 593, -206, 14, 671, 8, 6, - 20, 24, 29, 671, 634, 31, 671, 671, 671, 671, - 671, 3, -206, 4, -206, -206, -206, -21, -8, 707, - 671, 889, -206, -206, -206, -206, -206, -206, -206, -20, - 671, -206, 889, 889, 889, 889, 1, 671, 671, -206, - -206, 7, 671, -206, 671, -206, 37, -206, 889, 13, - -206, -206, 723, 54, -206, -38, 671, -34, 41, -206, - -206, 774, -206, 13, -206, -206, 10, -43, 797, -43, - -43, 843, -206, 332, 707, 671, 707, 43, 866, 889, - 671, 671, 671, 671, 671, 671, 671, 671, 671, 671, - 671, 671, 671, 671, 671, 671, 723, 671, -59, 1, - 67, 889, 889, 671, -206, -206, 69, -206, 671, 671, - 751, 671, 671, -206, -206, 671, -206, 71, 671, 671, - -206, -206, 18, 889, 19, 820, -61, 671, -206, 44, - 44, 44, -43, -43, -43, 889, 44, 44, 166, 224, - 224, -43, -43, 889, 889, 889, -206, -206, 889, 81, - -206, 889, 889, 671, 671, 889, 889, 81, 889, -206, - 889, 889, -206, -7, -206, -206, 529, 889, -206, -58, - 889, 889, -58, 396, 60, 671, 396, -206, -206, 84, - 27, 27, -206, -206, 85, 671, 889, -16, -12, -206, - 87, -206, -206, 73, 889, -206, 90, -206, 97, -206, - -206, 97, -206, 707, -206, 396, 396, -206, -206, 396, - -206, 396, 97, 97, -206, 707, 529, -206, 76, 86, - 396, 101, 104, -206, 105, 93, -206, -206, -206, -206, - 111, 114, 126, 127, -18, -206, 529, -206, 465, 120, - -206, -206, -206, 396, -206, -206, -206, -206, -206 + 272, -55, -214, -214, 825, -214, -214, 825, 825, 825, + 1013, -214, 1, 25, 749, -214, 32, 825, 29, 37, + 35, 41, 44, 825, 781, 51, 825, 825, 56, 825, + 825, 825, 3, -214, 4, -214, -214, -214, 7, 12, + 839, 825, 988, -214, -214, -214, -214, -214, -214, -214, + 8, 825, -214, 988, 988, 988, 988, 6, 825, 825, + -214, -214, 10, 825, -214, 825, -214, 57, -214, 988, + -14, -214, -214, 45, 66, -214, -36, 825, -35, 61, + -214, -214, 863, -214, -14, -214, -214, 23, -50, 888, + 21, -50, -50, 938, -214, 359, 839, 825, 839, 71, + 963, 988, 825, 825, 825, 825, 825, 825, 825, 825, + 825, 825, 825, 825, 825, 825, 825, 825, 45, 825, + -31, 6, 94, 988, 988, 825, -214, -214, 95, -214, + 825, 825, 673, 825, 825, -214, -214, 825, -214, 98, + 825, 825, -214, -214, -214, -214, 42, 988, 43, 913, + -55, 825, -214, -48, -48, -48, -50, -50, -50, 988, + -48, -48, 150, 174, 174, -50, -50, 988, 988, 988, + -214, -214, 988, 107, -214, 988, 988, 825, 825, 988, + 988, 107, 988, -214, 988, 988, -55, 58, -214, -3, + -214, -214, 691, 988, -214, -7, 988, 988, -7, -214, + -55, 567, 88, 825, 567, -214, -214, 118, 54, 54, + 425, -214, -214, -214, 131, 825, 988, -8, -16, -214, + 139, -214, -214, -214, 496, 122, 988, -214, 132, -214, + 140, -214, -214, 140, -214, 839, -214, 567, 567, -214, + -214, -214, 567, -214, 567, 140, 140, -214, 839, 691, + -214, 119, 125, 567, 142, 145, -214, 149, 135, -214, + -214, -214, -214, 152, 141, 151, 153, -20, -214, 691, + -214, 638, 143, -214, -214, -214, 567, -214, -214, -214, + -214, -214 }; /* YYPGOTO[NTERM-NUM]. */ static const yytype_int16 yypgoto[] = { - -206, -206, 11, 70, 2, -179, 0, -206, -206, -206, - -44, -205, -67, -63, -206, -206, -206, -203, -9, -13, - -141, -206, 39, 5, -206, -206, -206, 142, -11, -206, - -206, -206, -206, -4, -32, -206, 23 + -214, -214, 11, 91, 2, -181, 0, -214, -214, -214, + -30, -213, -58, -73, -214, -214, -214, -185, -9, -12, + 129, -214, 40, 5, -214, -214, -214, 166, -11, -214, + -214, -214, -214, -214, -214, 13, -13, -214, 24 }; /* YYTABLE[YYPACT[STATE-NUM]]. What to do in state STATE-NUM. If positive, shift that token. If negative, reduce the rule which number is the opposite. If zero, do what YYDEFACT says. If YYTABLE_NINF, syntax error. */ -#define YYTABLE_NINF -61 +#define YYTABLE_NINF -125 static const yytype_int16 yytable[] = { - 35, 58, 33, 92, -10, 42, 128, 197, -51, -51, - 131, 216, 48, 84, 219, 235, 237, 194, 47, 75, - 76, 47, 166, 106, 59, 117, 199, 77, 237, 235, - 60, 142, 217, 144, 129, 71, 220, 195, 132, 114, - 115, 78, 93, 52, 196, 79, 53, 54, 55, 64, - 80, 66, 85, 68, 73, 74, 72, 246, 124, 94, - 57, -51, 81, 68, 95, 87, 88, 89, 90, 91, - 225, 226, 136, 123, 229, 127, 231, 264, 98, 99, - 118, 119, 47, -10, 133, 117, 146, 240, 167, 116, - 170, 120, 179, 35, 137, 33, 55, 55, 42, 182, - 184, 121, 188, 122, 205, 209, 103, 104, 224, 105, - 106, 210, 213, 263, 227, 130, 169, 109, 110, 111, - 112, 113, 230, 219, 247, 177, 114, 115, 251, 249, - 183, 252, 253, 98, 143, 145, 254, 186, 259, 149, - 150, 151, 152, 153, 154, 155, 156, 157, 158, 159, - 160, 161, 162, 163, 164, 260, 165, 185, 261, 262, - 239, 266, 168, 141, 221, 243, 83, 171, 172, 212, - 175, 176, 245, 192, 178, 0, 0, 180, 181, 0, - 204, 0, 0, 207, 208, 0, 187, 0, 0, 0, - 0, 0, 0, 215, 0, 0, 0, 0, 218, 0, - 200, 228, 0, 201, 0, 0, 0, 0, 238, 0, - 0, 236, 190, 191, 0, 0, 241, 0, 242, 244, - 0, 0, 0, 0, 0, 0, 0, 250, 103, 104, - 0, 105, 106, 255, 206, 257, 0, 0, 256, 0, - 110, 111, 112, 113, 214, 0, 0, 0, 114, 115, - 267, 0, 268, 0, 0, 0, 0, 0, 265, 0, - 0, 0, 98, -6, 1, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 98, 2, 3, 4, 5, 0, - 6, 7, 8, 9, 10, 11, 103, 104, 0, 105, - 106, 12, 0, 13, 14, 15, 0, 0, 16, 0, - 112, 113, 0, 17, 18, 19, 114, 115, 20, 0, - 0, 0, 21, 22, 23, 24, 0, 0, 25, 0, - 0, 0, 0, 0, 0, 0, 0, 26, 0, 0, - 0, 0, 27, 0, 0, 0, 0, 28, 29, 0, - 0, 0, -6, 30, 2, 3, 4, 5, 0, 6, + 36, 59, 34, 94, -10, 43, -51, -51, 130, 133, + 231, 205, 49, 85, 105, 106, 108, 107, 108, 228, + 250, 202, 65, 146, 67, 148, 48, 111, 112, 113, + 114, 115, 232, 250, 116, 117, 116, 117, 131, 134, + 229, 203, 60, 95, 53, 248, 61, 54, 55, 56, + 76, 77, 170, 72, 69, 119, 79, 73, 78, 126, + 248, -51, 80, 82, 69, 81, 88, 89, 259, 91, + 92, 93, 86, 138, 48, 74, 75, 90, 128, 207, + 100, 101, 120, 121, 48, -10, 97, 129, 277, 96, + 58, 118, 119, 125, -124, 36, 122, 34, 56, 56, + 43, 102, 103, 123, 135, 124, 104, 105, 106, 139, + 107, 108, 109, 110, 150, 171, 174, 132, 173, 183, + 111, 112, 113, 114, 115, 188, 190, 181, 194, 116, + 117, 200, 215, 186, 187, 189, 100, 147, 149, 219, + 220, 192, 153, 154, 155, 156, 157, 158, 159, 160, + 161, 162, 163, 164, 165, 166, 167, 168, 225, 169, + 236, 191, 252, 240, 243, 172, 231, 260, 262, 264, + 175, 176, 265, 179, 180, 258, 266, 182, 267, 272, + 184, 185, 273, 274, 279, 275, 145, 256, 233, 214, + 84, 193, 217, 218, 198, 0, 222, 199, 0, 0, + 0, 0, 0, 0, 227, 0, 208, 0, 230, 209, + 0, 211, 105, 106, 241, 107, 108, 196, 197, 0, + 0, 251, 0, 249, 0, 0, 112, 113, 114, 115, + 254, 0, 255, 257, 116, 117, 105, 106, 0, 107, + 108, 263, 0, 216, 0, 0, 0, 268, 0, 270, + 0, 269, 114, 115, 0, 226, 0, 0, 116, 117, + 0, 0, 0, 0, 280, 0, 281, 0, 0, 0, + 0, 278, -6, 1, 0, 100, 0, 0, 0, 0, + 0, 0, 0, 0, 2, 3, 4, 5, 100, 6, 7, 8, 9, 10, 11, 0, 0, 0, 0, 0, 12, 0, 13, 14, 15, 0, 0, 16, 0, 0, 0, 0, 17, 18, 19, 0, 0, 20, 0, 0, - 0, 21, 22, 23, 24, 0, 0, 25, 0, 0, + 204, 21, 22, 23, 24, 0, 0, 25, 210, 0, 0, 0, 0, 0, 0, 0, 26, 0, 0, 0, - 0, 27, 0, 0, 0, 0, 28, 29, 2, 3, - 4, 5, 30, 6, 7, 8, 9, 49, 11, 0, - 0, 0, 0, 0, 12, 0, 13, 14, 15, 0, + 224, 27, 0, 0, 28, 0, 0, 0, 29, 30, + 237, 238, 0, -6, 31, 0, 242, 0, 244, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 253, 2, 3, 4, 5, 0, 6, 7, 8, 9, + 10, 11, 0, 0, 0, 0, 0, 12, 0, 13, + 14, 15, 0, 0, 16, 0, 276, 0, 0, 17, + 18, 19, 0, 0, 20, 0, 0, 0, 21, 22, + 23, 24, 0, 0, 25, 0, 0, 0, 0, 0, + 0, 0, 0, 26, 0, 0, 0, 0, 27, 0, + 0, 28, 0, 0, 0, 29, 30, 2, 3, 4, + 5, 31, 6, 7, 8, 9, 50, 11, 0, 0, + 0, 0, 223, 12, 0, 13, 14, 15, 0, 0, + 0, 0, 0, 0, 0, 17, 18, 19, 0, 0, + 20, 0, 0, 0, 0, 0, 23, 24, 0, 0, + 25, 0, 0, 0, 0, 0, 0, 0, 0, 26, + 0, 0, 0, 0, 27, 0, 0, 0, 0, 0, + 0, 29, 30, 0, 0, 0, 48, 31, 2, 3, + 4, 5, 0, 6, 7, 8, 9, 50, 11, 0, + 0, 0, 0, 239, 12, 0, 13, 14, 15, 0, 0, 0, 0, 0, 0, 0, 17, 18, 19, 0, 0, 20, 0, 0, 0, 0, 0, 23, 24, 0, 0, 25, 0, 0, 0, 0, 0, 0, 0, 0, 26, 0, 0, 0, 0, 27, 0, 0, 0, 0, - 28, 29, 0, 0, 0, 47, 30, 2, 3, 4, - 5, 0, 6, 7, 8, 9, 49, 11, 0, 0, - 0, 0, 0, 12, 0, 13, 14, 15, 0, 0, - 0, 0, 0, 0, 0, 17, 18, 19, 0, 0, - 20, 0, 0, 0, 0, 0, 23, 24, 0, 0, - 25, 0, 0, 0, 0, 0, 0, 0, 0, 26, - 0, 0, 0, 0, 27, 0, 0, 0, 0, 28, - 29, 2, 3, 4, 5, 30, 6, 7, 8, 9, - 49, 11, 0, 0, 0, 0, 0, 12, 0, 13, - 14, 0, 0, 0, 0, 0, 0, 0, 0, 17, - 0, 19, 0, 0, 0, 0, 0, 0, 0, 0, - 23, 24, 0, 0, 25, 0, 0, 0, 0, 0, - 0, 0, 0, 26, 0, 0, 0, 0, 27, 0, - 0, 0, 0, 28, 29, 2, 3, 4, 5, 30, - 6, 0, 0, 0, 49, 11, 0, 0, 0, 0, - 0, 0, 62, 0, 0, 0, 0, 63, 0, 64, - 65, 66, 67, 50, 0, 19, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 2, 3, 4, 5, - 0, 6, 0, 0, 0, 49, 11, 26, 0, 0, - 0, 0, 27, 62, 0, 0, 0, 28, 29, 0, - 64, 0, 66, 30, 50, 0, 19, 0, 0, 0, - 0, 0, 0, 2, 3, 4, 5, 82, 6, 0, - 0, 0, 49, 11, 0, 0, 0, 0, 26, 0, - 0, 0, 0, 27, 0, 0, 0, 0, 28, 29, - 0, 50, 0, 19, 30, 0, 0, 0, 0, 2, - 3, 4, 5, 0, 6, 0, 0, 0, 49, 11, - 0, 0, 0, 0, 0, 26, 0, 0, 0, 0, - 27, 0, 0, 0, 0, 28, 29, 50, 0, 19, - 0, 30, 0, 0, 0, 0, 126, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 26, 0, 0, 0, 0, 27, 0, 0, 100, - 101, 28, 29, 0, 102, 103, 104, 96, 105, 106, - 107, 108, 0, 0, 0, 173, 109, 110, 111, 112, - 113, 0, 0, 0, 0, 114, 115, 100, 101, 0, - 0, 0, 102, 103, 104, 0, 105, 106, 107, 108, - 135, 0, 0, 174, 109, 110, 111, 112, 113, 0, - 100, 101, 0, 114, 115, 102, 103, 104, 0, 105, - 106, 107, 108, 0, 0, 0, 0, 109, 110, 111, - 112, 113, 0, 100, 101, 0, 114, 115, 102, 103, - 104, 0, 105, 106, 107, 108, 0, 138, 139, 0, - 109, 110, 111, 112, 113, 0, 100, 101, 0, 114, - 115, 102, 103, 104, 0, 105, 106, 107, 108, 0, - 0, 0, 147, 109, 110, 111, 112, 113, 0, 100, - 101, 140, 114, 115, 102, 103, 104, 0, 105, 106, - 107, 108, 0, 0, 0, 0, 109, 110, 111, 112, - 113, 0, 100, 101, 140, 114, 115, 102, 103, 104, - 0, 105, 106, 107, 108, 0, 0, 0, 147, 109, - 110, 111, 112, 113, 0, 100, 101, 0, 114, 115, - 102, 103, 104, 0, 105, 106, 107, 108, 0, 0, - 0, 0, 109, 110, 111, 112, 113, 0, -60, -60, - 0, 114, 115, -60, -60, -60, 0, -60, -60, -60, - -60, 0, 0, 0, 0, -60, 0, 0, -60, -60, - 0, 0, 57, 0, -60, -60 + 0, 0, 29, 30, 0, 0, 0, 48, 31, 2, + 3, 4, 5, 0, 6, 7, 8, 9, 50, 11, + 0, 0, 0, 0, 0, 12, 0, 13, 14, 15, + 0, 0, 0, 0, 0, 0, 0, 17, 18, 19, + 0, 0, 20, 0, 0, 0, 0, 0, 23, 24, + 0, 0, 25, 0, 0, 0, 0, 0, 0, 0, + 0, 26, 0, 0, 0, 0, 27, 0, 0, 0, + 0, 0, 0, 29, 30, 0, 0, 0, 48, 31, + 2, 3, 4, 5, 0, 6, 7, 8, 9, 50, + 11, 0, 0, 0, 0, 0, 12, 0, 13, 14, + 15, 0, 0, 0, 0, 0, 0, 0, 17, 18, + 19, 0, 0, 20, 0, 0, 0, 0, 0, 23, + 24, 0, 0, 25, 0, 0, 0, 0, 0, 0, + 0, 0, 26, 2, 3, 4, 5, 27, 6, 7, + 8, 9, 50, 11, 29, 30, 0, 177, 0, 12, + 31, 13, 14, 0, 0, 0, 0, 0, 0, 102, + 103, 17, 0, 19, 104, 105, 106, 0, 107, 108, + 109, 110, 23, 24, 0, 0, 25, 178, 111, 112, + 113, 114, 115, 0, 0, 26, 0, 116, 117, 0, + 27, 2, 3, 4, 5, 0, 6, 29, 30, 0, + 50, 11, 0, 31, 0, 0, 0, 0, 63, 0, + 0, 0, 0, 64, 0, 65, 66, 67, 68, 51, + 0, 19, 0, 2, 3, 4, 5, 0, 6, 0, + 0, 0, 50, 11, 0, 0, 0, 0, 0, 0, + 63, 0, 0, 26, 0, 0, 0, 65, 27, 67, + 0, 51, 0, 19, 0, 29, 30, 0, 0, 0, + 0, 31, 0, 0, 83, 0, 0, 2, 3, 4, + 5, 0, 6, 0, 0, 26, 50, 11, 0, 0, + 27, 2, 3, 4, 5, 0, 6, 29, 30, 0, + 50, 11, 0, 31, 0, 51, 0, 19, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 51, + 0, 19, 0, 0, 0, 0, 0, 0, 0, 26, + 0, 0, 0, 0, 27, 0, 0, 0, 0, 0, + 0, 29, 30, 26, 0, 0, 0, 31, 27, 137, + 0, 0, 0, 0, 0, 29, 30, 0, 0, 102, + 103, 98, 0, 0, 104, 105, 106, 0, 107, 108, + 109, 110, 0, 0, 0, 0, 0, 0, 111, 112, + 113, 114, 115, 0, 102, 103, 0, 116, 117, 104, + 105, 106, 0, 107, 108, 109, 110, 0, 140, 141, + 0, 0, 0, 111, 112, 113, 114, 115, 0, 102, + 103, 0, 116, 117, 104, 105, 106, 0, 107, 108, + 109, 110, 0, 0, 0, 0, 0, 151, 111, 112, + 113, 114, 115, 0, 102, 103, 144, 116, 117, 104, + 105, 106, 0, 107, 108, 109, 110, 0, 0, 0, + 0, 0, 0, 111, 112, 113, 114, 115, 0, 102, + 103, 144, 116, 117, 104, 105, 106, 0, 107, 108, + 109, 110, 0, 0, 0, 0, 0, 151, 111, 112, + 113, 114, 115, 0, 102, 103, 0, 116, 117, 104, + 105, 106, 0, 107, 108, 109, 110, 0, 0, 0, + 0, 0, 0, 111, 112, 113, 114, 115, 0, -60, + -60, 0, 116, 117, -60, -60, -60, 0, -60, -60, + -60, -60, 0, 0, 0, 0, 0, 0, -60, 0, + 0, -60, -60, 0, 0, 58, 0, -60, -60 }; static const yytype_int16 yycheck[] = { - 0, 10, 0, 0, 0, 0, 44, 186, 26, 27, - 44, 27, 1, 24, 26, 218, 221, 24, 79, 13, - 14, 79, 81, 66, 41, 84, 84, 21, 233, 232, - 21, 94, 48, 96, 72, 21, 48, 44, 72, 82, - 83, 21, 31, 4, 185, 21, 7, 8, 9, 36, - 21, 38, 21, 14, 46, 47, 17, 236, 69, 80, - 80, 79, 23, 24, 72, 26, 27, 28, 29, 30, - 211, 212, 83, 36, 215, 21, 217, 256, 39, 40, - 57, 58, 79, 79, 43, 84, 43, 228, 21, 50, - 21, 84, 21, 93, 84, 93, 57, 58, 93, 81, - 81, 62, 21, 64, 44, 21, 62, 63, 21, 65, - 66, 84, 27, 254, 41, 76, 125, 73, 74, 75, - 76, 77, 32, 26, 48, 134, 82, 83, 27, 43, - 143, 27, 27, 94, 95, 96, 43, 146, 27, 100, - 101, 102, 103, 104, 105, 106, 107, 108, 109, 110, - 111, 112, 113, 114, 115, 41, 117, 146, 32, 32, - 223, 41, 123, 93, 208, 232, 24, 128, 129, 201, - 131, 132, 235, 177, 135, -1, -1, 138, 139, -1, - 193, -1, -1, 196, 197, -1, 147, -1, -1, -1, - -1, -1, -1, 206, -1, -1, -1, -1, 207, -1, - 189, 214, -1, 192, -1, -1, -1, -1, 221, -1, - -1, 220, 173, 174, -1, -1, 229, -1, 231, 232, - -1, -1, -1, -1, -1, -1, -1, 240, 62, 63, - -1, 65, 66, 246, 195, 248, -1, -1, 247, -1, - 74, 75, 76, 77, 205, -1, -1, -1, 82, 83, - 263, -1, 265, -1, -1, -1, -1, -1, 258, -1, - -1, -1, 223, 0, 1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, 235, 12, 13, 14, 15, -1, - 17, 18, 19, 20, 21, 22, 62, 63, -1, 65, - 66, 28, -1, 30, 31, 32, -1, -1, 35, -1, - 76, 77, -1, 40, 41, 42, 82, 83, 45, -1, - -1, -1, 49, 50, 51, 52, -1, -1, 55, -1, - -1, -1, -1, -1, -1, -1, -1, 64, -1, -1, - -1, -1, 69, -1, -1, -1, -1, 74, 75, -1, - -1, -1, 79, 80, 12, 13, 14, 15, -1, 17, + 0, 10, 0, 0, 0, 0, 26, 27, 44, 44, + 26, 192, 1, 24, 62, 63, 66, 65, 66, 27, + 233, 24, 36, 96, 38, 98, 81, 75, 76, 77, + 78, 79, 48, 246, 84, 85, 84, 85, 74, 74, + 48, 44, 41, 32, 4, 230, 21, 7, 8, 9, + 13, 14, 83, 21, 14, 86, 21, 17, 21, 70, + 245, 81, 21, 23, 24, 21, 26, 27, 249, 29, + 30, 31, 21, 84, 81, 46, 47, 21, 33, 86, + 40, 41, 58, 59, 81, 81, 74, 21, 269, 82, + 82, 51, 86, 36, 73, 95, 86, 95, 58, 59, + 95, 56, 57, 63, 43, 65, 61, 62, 63, 86, + 65, 66, 67, 68, 43, 21, 21, 77, 127, 21, + 75, 76, 77, 78, 79, 83, 83, 136, 21, 84, + 85, 73, 44, 142, 143, 147, 96, 97, 98, 21, + 86, 150, 102, 103, 104, 105, 106, 107, 108, 109, + 110, 111, 112, 113, 114, 115, 116, 117, 27, 119, + 21, 150, 235, 41, 32, 125, 26, 48, 43, 27, + 130, 131, 27, 133, 134, 248, 27, 137, 43, 27, + 140, 141, 41, 32, 41, 32, 95, 245, 218, 201, + 24, 151, 204, 205, 181, -1, 209, 186, -1, -1, + -1, -1, -1, -1, 216, -1, 195, -1, 217, 198, + -1, 200, 62, 63, 226, 65, 66, 177, 178, -1, + -1, 233, -1, 232, -1, -1, 76, 77, 78, 79, + 242, -1, 244, 245, 84, 85, 62, 63, -1, 65, + 66, 253, -1, 203, -1, -1, -1, 259, -1, 261, + -1, 260, 78, 79, -1, 215, -1, -1, 84, 85, + -1, -1, -1, -1, 276, -1, 278, -1, -1, -1, + -1, 271, 0, 1, -1, 235, -1, -1, -1, -1, + -1, -1, -1, -1, 12, 13, 14, 15, 248, 17, 18, 19, 20, 21, 22, -1, -1, -1, -1, -1, 28, -1, 30, 31, 32, -1, -1, 35, -1, -1, -1, -1, 40, 41, 42, -1, -1, 45, -1, -1, - -1, 49, 50, 51, 52, -1, -1, 55, -1, -1, + 191, 49, 50, 51, 52, -1, -1, 55, 199, -1, -1, -1, -1, -1, -1, -1, 64, -1, -1, -1, - -1, 69, -1, -1, -1, -1, 74, 75, 12, 13, - 14, 15, 80, 17, 18, 19, 20, 21, 22, -1, - -1, -1, -1, -1, 28, -1, 30, 31, 32, -1, + 211, 69, -1, -1, 72, -1, -1, -1, 76, 77, + 221, 222, -1, 81, 82, -1, 227, -1, 229, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, + 241, 12, 13, 14, 15, -1, 17, 18, 19, 20, + 21, 22, -1, -1, -1, -1, -1, 28, -1, 30, + 31, 32, -1, -1, 35, -1, 267, -1, -1, 40, + 41, 42, -1, -1, 45, -1, -1, -1, 49, 50, + 51, 52, -1, -1, 55, -1, -1, -1, -1, -1, + -1, -1, -1, 64, -1, -1, -1, -1, 69, -1, + -1, 72, -1, -1, -1, 76, 77, 12, 13, 14, + 15, 82, 17, 18, 19, 20, 21, 22, -1, -1, + -1, -1, 27, 28, -1, 30, 31, 32, -1, -1, + -1, -1, -1, -1, -1, 40, 41, 42, -1, -1, + 45, -1, -1, -1, -1, -1, 51, 52, -1, -1, + 55, -1, -1, -1, -1, -1, -1, -1, -1, 64, + -1, -1, -1, -1, 69, -1, -1, -1, -1, -1, + -1, 76, 77, -1, -1, -1, 81, 82, 12, 13, + 14, 15, -1, 17, 18, 19, 20, 21, 22, -1, + -1, -1, -1, 27, 28, -1, 30, 31, 32, -1, -1, -1, -1, -1, -1, -1, 40, 41, 42, -1, -1, 45, -1, -1, -1, -1, -1, 51, 52, -1, -1, 55, -1, -1, -1, -1, -1, -1, -1, -1, 64, -1, -1, -1, -1, 69, -1, -1, -1, -1, - 74, 75, -1, -1, -1, 79, 80, 12, 13, 14, - 15, -1, 17, 18, 19, 20, 21, 22, -1, -1, - -1, -1, -1, 28, -1, 30, 31, 32, -1, -1, - -1, -1, -1, -1, -1, 40, 41, 42, -1, -1, - 45, -1, -1, -1, -1, -1, 51, 52, -1, -1, - 55, -1, -1, -1, -1, -1, -1, -1, -1, 64, - -1, -1, -1, -1, 69, -1, -1, -1, -1, 74, - 75, 12, 13, 14, 15, 80, 17, 18, 19, 20, - 21, 22, -1, -1, -1, -1, -1, 28, -1, 30, - 31, -1, -1, -1, -1, -1, -1, -1, -1, 40, - -1, 42, -1, -1, -1, -1, -1, -1, -1, -1, - 51, 52, -1, -1, 55, -1, -1, -1, -1, -1, - -1, -1, -1, 64, -1, -1, -1, -1, 69, -1, - -1, -1, -1, 74, 75, 12, 13, 14, 15, 80, - 17, -1, -1, -1, 21, 22, -1, -1, -1, -1, - -1, -1, 29, -1, -1, -1, -1, 34, -1, 36, - 37, 38, 39, 40, -1, 42, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, 12, 13, 14, 15, - -1, 17, -1, -1, -1, 21, 22, 64, -1, -1, - -1, -1, 69, 29, -1, -1, -1, 74, 75, -1, - 36, -1, 38, 80, 40, -1, 42, -1, -1, -1, - -1, -1, -1, 12, 13, 14, 15, 53, 17, -1, - -1, -1, 21, 22, -1, -1, -1, -1, 64, -1, - -1, -1, -1, 69, -1, -1, -1, -1, 74, 75, - -1, 40, -1, 42, 80, -1, -1, -1, -1, 12, - 13, 14, 15, -1, 17, -1, -1, -1, 21, 22, - -1, -1, -1, -1, -1, 64, -1, -1, -1, -1, - 69, -1, -1, -1, -1, 74, 75, 40, -1, 42, - -1, 80, -1, -1, -1, -1, 33, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, 64, -1, -1, -1, -1, 69, -1, -1, 56, - 57, 74, 75, -1, 61, 62, 63, 80, 65, 66, - 67, 68, -1, -1, -1, 44, 73, 74, 75, 76, - 77, -1, -1, -1, -1, 82, 83, 56, 57, -1, - -1, -1, 61, 62, 63, -1, 65, 66, 67, 68, - 46, -1, -1, 72, 73, 74, 75, 76, 77, -1, - 56, 57, -1, 82, 83, 61, 62, 63, -1, 65, - 66, 67, 68, -1, -1, -1, -1, 73, 74, 75, - 76, 77, -1, 56, 57, -1, 82, 83, 61, 62, - 63, -1, 65, 66, 67, 68, -1, 70, 71, -1, - 73, 74, 75, 76, 77, -1, 56, 57, -1, 82, - 83, 61, 62, 63, -1, 65, 66, 67, 68, -1, - -1, -1, 72, 73, 74, 75, 76, 77, -1, 56, - 57, 81, 82, 83, 61, 62, 63, -1, 65, 66, - 67, 68, -1, -1, -1, -1, 73, 74, 75, 76, - 77, -1, 56, 57, 81, 82, 83, 61, 62, 63, - -1, 65, 66, 67, 68, -1, -1, -1, 72, 73, - 74, 75, 76, 77, -1, 56, 57, -1, 82, 83, - 61, 62, 63, -1, 65, 66, 67, 68, -1, -1, - -1, -1, 73, 74, 75, 76, 77, -1, 56, 57, - -1, 82, 83, 61, 62, 63, -1, 65, 66, 67, - 68, -1, -1, -1, -1, 73, -1, -1, 76, 77, - -1, -1, 80, -1, 82, 83 + -1, -1, 76, 77, -1, -1, -1, 81, 82, 12, + 13, 14, 15, -1, 17, 18, 19, 20, 21, 22, + -1, -1, -1, -1, -1, 28, -1, 30, 31, 32, + -1, -1, -1, -1, -1, -1, -1, 40, 41, 42, + -1, -1, 45, -1, -1, -1, -1, -1, 51, 52, + -1, -1, 55, -1, -1, -1, -1, -1, -1, -1, + -1, 64, -1, -1, -1, -1, 69, -1, -1, -1, + -1, -1, -1, 76, 77, -1, -1, -1, 81, 82, + 12, 13, 14, 15, -1, 17, 18, 19, 20, 21, + 22, -1, -1, -1, -1, -1, 28, -1, 30, 31, + 32, -1, -1, -1, -1, -1, -1, -1, 40, 41, + 42, -1, -1, 45, -1, -1, -1, -1, -1, 51, + 52, -1, -1, 55, -1, -1, -1, -1, -1, -1, + -1, -1, 64, 12, 13, 14, 15, 69, 17, 18, + 19, 20, 21, 22, 76, 77, -1, 44, -1, 28, + 82, 30, 31, -1, -1, -1, -1, -1, -1, 56, + 57, 40, -1, 42, 61, 62, 63, -1, 65, 66, + 67, 68, 51, 52, -1, -1, 55, 74, 75, 76, + 77, 78, 79, -1, -1, 64, -1, 84, 85, -1, + 69, 12, 13, 14, 15, -1, 17, 76, 77, -1, + 21, 22, -1, 82, -1, -1, -1, -1, 29, -1, + -1, -1, -1, 34, -1, 36, 37, 38, 39, 40, + -1, 42, -1, 12, 13, 14, 15, -1, 17, -1, + -1, -1, 21, 22, -1, -1, -1, -1, -1, -1, + 29, -1, -1, 64, -1, -1, -1, 36, 69, 38, + -1, 40, -1, 42, -1, 76, 77, -1, -1, -1, + -1, 82, -1, -1, 53, -1, -1, 12, 13, 14, + 15, -1, 17, -1, -1, 64, 21, 22, -1, -1, + 69, 12, 13, 14, 15, -1, 17, 76, 77, -1, + 21, 22, -1, 82, -1, 40, -1, 42, -1, -1, + -1, -1, -1, -1, -1, -1, -1, -1, -1, 40, + -1, 42, -1, -1, -1, -1, -1, -1, -1, 64, + -1, -1, -1, -1, 69, -1, -1, -1, -1, -1, + -1, 76, 77, 64, -1, -1, -1, 82, 69, 46, + -1, -1, -1, -1, -1, 76, 77, -1, -1, 56, + 57, 82, -1, -1, 61, 62, 63, -1, 65, 66, + 67, 68, -1, -1, -1, -1, -1, -1, 75, 76, + 77, 78, 79, -1, 56, 57, -1, 84, 85, 61, + 62, 63, -1, 65, 66, 67, 68, -1, 70, 71, + -1, -1, -1, 75, 76, 77, 78, 79, -1, 56, + 57, -1, 84, 85, 61, 62, 63, -1, 65, 66, + 67, 68, -1, -1, -1, -1, -1, 74, 75, 76, + 77, 78, 79, -1, 56, 57, 83, 84, 85, 61, + 62, 63, -1, 65, 66, 67, 68, -1, -1, -1, + -1, -1, -1, 75, 76, 77, 78, 79, -1, 56, + 57, 83, 84, 85, 61, 62, 63, -1, 65, 66, + 67, 68, -1, -1, -1, -1, -1, 74, 75, 76, + 77, 78, 79, -1, 56, 57, -1, 84, 85, 61, + 62, 63, -1, 65, 66, 67, 68, -1, -1, -1, + -1, -1, -1, 75, 76, 77, 78, 79, -1, 56, + 57, -1, 84, 85, 61, 62, 63, -1, 65, 66, + 67, 68, -1, -1, -1, -1, -1, -1, 75, -1, + -1, 78, 79, -1, -1, 82, -1, 84, 85 }; /* YYSTOS[STATE-NUM] -- The (internal number of the) accessing @@ -1030,31 +1060,33 @@ static const yytype_uint8 yystos[] = { 0, 1, 12, 13, 14, 15, 17, 18, 19, 20, 21, 22, 28, 30, 31, 32, 35, 40, 41, 42, - 45, 49, 50, 51, 52, 55, 64, 69, 74, 75, - 80, 86, 88, 89, 90, 91, 92, 99, 100, 101, - 106, 107, 108, 111, 114, 115, 120, 79, 87, 21, - 40, 89, 107, 107, 107, 107, 121, 80, 103, 41, - 21, 109, 29, 34, 36, 37, 38, 39, 107, 112, - 113, 21, 107, 46, 47, 13, 14, 21, 21, 21, - 21, 107, 53, 112, 113, 21, 110, 107, 107, 107, - 107, 107, 0, 87, 80, 72, 80, 98, 107, 107, - 56, 57, 61, 62, 63, 65, 66, 67, 68, 73, - 74, 75, 76, 77, 82, 83, 107, 84, 121, 121, - 84, 107, 107, 36, 113, 116, 33, 21, 44, 72, - 107, 44, 72, 43, 117, 46, 113, 84, 70, 71, - 81, 88, 98, 107, 98, 107, 43, 72, 104, 107, - 107, 107, 107, 107, 107, 107, 107, 107, 107, 107, - 107, 107, 107, 107, 107, 107, 81, 21, 107, 103, - 21, 107, 107, 44, 72, 107, 107, 103, 107, 21, - 107, 107, 81, 104, 81, 87, 103, 107, 21, 118, - 107, 107, 118, 105, 24, 44, 105, 90, 108, 84, - 87, 87, 87, 91, 104, 44, 107, 104, 104, 21, - 84, 119, 119, 27, 107, 104, 27, 48, 103, 26, - 48, 95, 96, 102, 21, 105, 105, 41, 104, 105, - 32, 105, 94, 95, 97, 102, 103, 96, 104, 98, - 105, 104, 104, 97, 104, 98, 90, 48, 93, 43, - 104, 27, 27, 27, 43, 104, 103, 104, 103, 27, - 41, 32, 32, 105, 90, 91, 41, 104, 104 + 45, 49, 50, 51, 52, 55, 64, 69, 72, 76, + 77, 82, 88, 90, 91, 92, 93, 94, 101, 102, + 103, 108, 109, 110, 113, 116, 117, 124, 81, 89, + 21, 40, 91, 109, 109, 109, 109, 125, 82, 105, + 41, 21, 111, 29, 34, 36, 37, 38, 39, 109, + 114, 115, 21, 109, 46, 47, 13, 14, 21, 21, + 21, 21, 109, 53, 114, 115, 21, 112, 109, 109, + 21, 109, 109, 109, 0, 89, 82, 74, 82, 100, + 109, 109, 56, 57, 61, 62, 63, 65, 66, 67, + 68, 75, 76, 77, 78, 79, 84, 85, 109, 86, + 125, 125, 86, 109, 109, 36, 115, 118, 33, 21, + 44, 74, 109, 44, 74, 43, 119, 46, 115, 86, + 70, 71, 120, 121, 83, 90, 100, 109, 100, 109, + 43, 74, 106, 109, 109, 109, 109, 109, 109, 109, + 109, 109, 109, 109, 109, 109, 109, 109, 109, 109, + 83, 21, 109, 105, 21, 109, 109, 44, 74, 109, + 109, 105, 109, 21, 109, 109, 105, 105, 83, 106, + 83, 89, 105, 109, 21, 122, 109, 109, 122, 89, + 73, 107, 24, 44, 107, 92, 110, 86, 89, 89, + 107, 89, 89, 93, 106, 44, 109, 106, 106, 21, + 86, 123, 123, 27, 107, 27, 109, 106, 27, 48, + 105, 26, 48, 97, 98, 104, 21, 107, 107, 27, + 41, 106, 107, 32, 107, 96, 97, 99, 104, 105, + 98, 106, 100, 107, 106, 106, 99, 106, 100, 92, + 48, 95, 43, 106, 27, 27, 27, 43, 106, 105, + 106, 105, 27, 41, 32, 32, 107, 92, 93, 41, + 106, 106 }; #define yyerrok (yyerrstatus = 0) @@ -1624,7 +1656,7 @@ yyparse () #endif #endif { - + int yystate; int yyn; int yyresult; @@ -1869,12 +1901,12 @@ yyreduce: switch (yyn) { case 4: -#line 107 "engines/director/lingo/lingo-gr.y" +#line 108 "engines/director/lingo/lingo-gr.y" { yyerrok; ;} break; case 5: -#line 110 "engines/director/lingo/lingo-gr.y" +#line 111 "engines/director/lingo/lingo-gr.y" { g_lingo->_linenumber++; g_lingo->_colnumber = 1; @@ -1882,12 +1914,12 @@ yyreduce: break; case 10: -#line 119 "engines/director/lingo/lingo-gr.y" +#line 120 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(g_lingo->c_xpop); ;} break; case 12: -#line 123 "engines/director/lingo/lingo-gr.y" +#line 124 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(g_lingo->c_varpush); g_lingo->codeString((yyvsp[(4) - (4)].s)->c_str()); @@ -1897,7 +1929,7 @@ yyreduce: break; case 13: -#line 129 "engines/director/lingo/lingo-gr.y" +#line 130 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(g_lingo->c_varpush); g_lingo->codeString((yyvsp[(2) - (4)].s)->c_str()); @@ -1907,7 +1939,7 @@ yyreduce: break; case 14: -#line 135 "engines/director/lingo/lingo-gr.y" +#line 136 "engines/director/lingo/lingo-gr.y" { g_lingo->codeConst(0); // Put dummy id g_lingo->code1(g_lingo->c_theentityassign); @@ -1919,7 +1951,7 @@ yyreduce: break; case 15: -#line 143 "engines/director/lingo/lingo-gr.y" +#line 144 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(g_lingo->c_swap); g_lingo->code1(g_lingo->c_theentityassign); @@ -1931,7 +1963,7 @@ yyreduce: break; case 16: -#line 151 "engines/director/lingo/lingo-gr.y" +#line 152 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(g_lingo->c_varpush); g_lingo->codeString((yyvsp[(2) - (4)].s)->c_str()); @@ -1941,7 +1973,7 @@ yyreduce: break; case 17: -#line 157 "engines/director/lingo/lingo-gr.y" +#line 158 "engines/director/lingo/lingo-gr.y" { g_lingo->codeConst(0); // Put dummy id g_lingo->code1(g_lingo->c_theentityassign); @@ -1953,7 +1985,7 @@ yyreduce: break; case 18: -#line 165 "engines/director/lingo/lingo-gr.y" +#line 166 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(g_lingo->c_swap); g_lingo->code1(g_lingo->c_theentityassign); @@ -1965,12 +1997,12 @@ yyreduce: break; case 19: -#line 174 "engines/director/lingo/lingo-gr.y" +#line 175 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(g_lingo->c_xpop); ;} break; case 23: -#line 183 "engines/director/lingo/lingo-gr.y" +#line 184 "engines/director/lingo/lingo-gr.y" { inst body = 0, end = 0; WRITE_UINT32(&body, (yyvsp[(5) - (8)].code)); @@ -1980,7 +2012,7 @@ yyreduce: break; case 24: -#line 194 "engines/director/lingo/lingo-gr.y" +#line 195 "engines/director/lingo/lingo-gr.y" { inst init = 0, finish = 0, body = 0, end = 0, inc = 0; WRITE_UINT32(&init, (yyvsp[(3) - (11)].code)); @@ -1996,7 +2028,7 @@ yyreduce: break; case 25: -#line 210 "engines/director/lingo/lingo-gr.y" +#line 211 "engines/director/lingo/lingo-gr.y" { inst init = 0, finish = 0, body = 0, end = 0, inc = 0; WRITE_UINT32(&init, (yyvsp[(3) - (12)].code)); @@ -2012,7 +2044,7 @@ yyreduce: break; case 26: -#line 222 "engines/director/lingo/lingo-gr.y" +#line 223 "engines/director/lingo/lingo-gr.y" { inst end = 0; WRITE_UINT32(&end, (yyvsp[(3) - (3)].code)); @@ -2022,7 +2054,7 @@ yyreduce: break; case 27: -#line 230 "engines/director/lingo/lingo-gr.y" +#line 231 "engines/director/lingo/lingo-gr.y" { inst then = 0, end = 0; WRITE_UINT32(&then, (yyvsp[(5) - (8)].code)); @@ -2033,7 +2065,7 @@ yyreduce: break; case 28: -#line 237 "engines/director/lingo/lingo-gr.y" +#line 238 "engines/director/lingo/lingo-gr.y" { inst then = 0, else1 = 0, end = 0; WRITE_UINT32(&then, (yyvsp[(5) - (11)].code)); @@ -2046,7 +2078,7 @@ yyreduce: break; case 29: -#line 246 "engines/director/lingo/lingo-gr.y" +#line 247 "engines/director/lingo/lingo-gr.y" { inst then = 0, else1 = 0, end = 0; WRITE_UINT32(&then, (yyvsp[(5) - (11)].code)); @@ -2059,7 +2091,7 @@ yyreduce: break; case 30: -#line 255 "engines/director/lingo/lingo-gr.y" +#line 256 "engines/director/lingo/lingo-gr.y" { inst then = 0, else1 = 0, end = 0; WRITE_UINT32(&then, (yyvsp[(4) - (6)].code)); @@ -2073,7 +2105,7 @@ yyreduce: break; case 31: -#line 265 "engines/director/lingo/lingo-gr.y" +#line 266 "engines/director/lingo/lingo-gr.y" { inst then = 0, else1 = 0, end = 0; WRITE_UINT32(&then, (yyvsp[(4) - (10)].code)); @@ -2087,7 +2119,7 @@ yyreduce: break; case 32: -#line 275 "engines/director/lingo/lingo-gr.y" +#line 276 "engines/director/lingo/lingo-gr.y" { inst then = 0, else1 = 0, end = 0; WRITE_UINT32(&then, (yyvsp[(4) - (10)].code)); @@ -2101,17 +2133,17 @@ yyreduce: break; case 33: -#line 286 "engines/director/lingo/lingo-gr.y" +#line 287 "engines/director/lingo/lingo-gr.y" { (yyval.code) = 0; ;} break; case 34: -#line 287 "engines/director/lingo/lingo-gr.y" +#line 288 "engines/director/lingo/lingo-gr.y" { (yyval.code) = (yyvsp[(2) - (3)].code); ;} break; case 39: -#line 298 "engines/director/lingo/lingo-gr.y" +#line 299 "engines/director/lingo/lingo-gr.y" { inst then = 0; WRITE_UINT32(&then, (yyvsp[(4) - (6)].code)); @@ -2121,7 +2153,7 @@ yyreduce: break; case 41: -#line 307 "engines/director/lingo/lingo-gr.y" +#line 308 "engines/director/lingo/lingo-gr.y" { inst then = 0; WRITE_UINT32(&then, (yyvsp[(4) - (5)].code)); @@ -2131,22 +2163,22 @@ yyreduce: break; case 42: -#line 315 "engines/director/lingo/lingo-gr.y" +#line 316 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(STOP); ;} break; case 43: -#line 316 "engines/director/lingo/lingo-gr.y" +#line 317 "engines/director/lingo/lingo-gr.y" { g_lingo->code2(g_lingo->c_eq, STOP); ;} break; case 45: -#line 319 "engines/director/lingo/lingo-gr.y" +#line 320 "engines/director/lingo/lingo-gr.y" { (yyval.code) = g_lingo->code3(g_lingo->c_repeatwhilecode, STOP, STOP); ;} break; case 46: -#line 321 "engines/director/lingo/lingo-gr.y" +#line 322 "engines/director/lingo/lingo-gr.y" { (yyval.code) = g_lingo->code3(g_lingo->c_repeatwithcode, STOP, STOP); g_lingo->code3(STOP, STOP, STOP); @@ -2155,7 +2187,7 @@ yyreduce: break; case 47: -#line 327 "engines/director/lingo/lingo-gr.y" +#line 328 "engines/director/lingo/lingo-gr.y" { (yyval.code) = g_lingo->code1(g_lingo->c_ifcode); g_lingo->code3(STOP, STOP, STOP); @@ -2164,7 +2196,7 @@ yyreduce: break; case 48: -#line 333 "engines/director/lingo/lingo-gr.y" +#line 334 "engines/director/lingo/lingo-gr.y" { inst skipEnd; WRITE_UINT32(&skipEnd, 1); // We have to skip end to avoid multiple executions @@ -2174,22 +2206,22 @@ yyreduce: break; case 49: -#line 340 "engines/director/lingo/lingo-gr.y" +#line 341 "engines/director/lingo/lingo-gr.y" { (yyval.code) = g_lingo->_currentScript->size(); ;} break; case 50: -#line 342 "engines/director/lingo/lingo-gr.y" +#line 343 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(STOP); (yyval.code) = g_lingo->_currentScript->size(); ;} break; case 51: -#line 344 "engines/director/lingo/lingo-gr.y" +#line 345 "engines/director/lingo/lingo-gr.y" { (yyval.code) = g_lingo->_currentScript->size(); ;} break; case 54: -#line 349 "engines/director/lingo/lingo-gr.y" +#line 350 "engines/director/lingo/lingo-gr.y" { (yyval.code) = g_lingo->code1(g_lingo->c_whencode); g_lingo->code1(STOP); @@ -2198,40 +2230,40 @@ yyreduce: break; case 55: -#line 355 "engines/director/lingo/lingo-gr.y" +#line 356 "engines/director/lingo/lingo-gr.y" { (yyval.code) = g_lingo->codeConst((yyvsp[(1) - (1)].i)); ;} break; case 56: -#line 356 "engines/director/lingo/lingo-gr.y" +#line 357 "engines/director/lingo/lingo-gr.y" { (yyval.code) = g_lingo->code1(g_lingo->c_fconstpush); g_lingo->codeFloat((yyvsp[(1) - (1)].f)); ;} break; case 57: -#line 359 "engines/director/lingo/lingo-gr.y" +#line 360 "engines/director/lingo/lingo-gr.y" { (yyval.code) = g_lingo->code1(g_lingo->c_stringpush); g_lingo->codeString((yyvsp[(1) - (1)].s)->c_str()); ;} break; case 58: -#line 362 "engines/director/lingo/lingo-gr.y" +#line 363 "engines/director/lingo/lingo-gr.y" { (yyval.code) = g_lingo->code1(g_lingo->_handlers[*(yyvsp[(1) - (1)].s)]->u.func); delete (yyvsp[(1) - (1)].s); ;} break; case 59: -#line 365 "engines/director/lingo/lingo-gr.y" +#line 366 "engines/director/lingo/lingo-gr.y" { (yyval.code) = g_lingo->codeFunc((yyvsp[(1) - (4)].s), (yyvsp[(3) - (4)].narg)); delete (yyvsp[(1) - (4)].s); ;} break; case 60: -#line 368 "engines/director/lingo/lingo-gr.y" +#line 369 "engines/director/lingo/lingo-gr.y" { (yyval.code) = g_lingo->code1(g_lingo->c_eval); g_lingo->codeString((yyvsp[(1) - (1)].s)->c_str()); @@ -2239,7 +2271,7 @@ yyreduce: break; case 61: -#line 372 "engines/director/lingo/lingo-gr.y" +#line 373 "engines/director/lingo/lingo-gr.y" { (yyval.code) = g_lingo->codeConst(0); // Put dummy id g_lingo->code1(g_lingo->c_theentitypush); @@ -2250,7 +2282,7 @@ yyreduce: break; case 62: -#line 379 "engines/director/lingo/lingo-gr.y" +#line 380 "engines/director/lingo/lingo-gr.y" { (yyval.code) = g_lingo->code1(g_lingo->c_theentitypush); inst e = 0, f = 0; @@ -2260,256 +2292,256 @@ yyreduce: break; case 64: -#line 386 "engines/director/lingo/lingo-gr.y" +#line 387 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(g_lingo->c_add); ;} break; case 65: -#line 387 "engines/director/lingo/lingo-gr.y" +#line 388 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(g_lingo->c_sub); ;} break; case 66: -#line 388 "engines/director/lingo/lingo-gr.y" +#line 389 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(g_lingo->c_mul); ;} break; case 67: -#line 389 "engines/director/lingo/lingo-gr.y" +#line 390 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(g_lingo->c_div); ;} break; case 68: -#line 390 "engines/director/lingo/lingo-gr.y" +#line 391 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(g_lingo->c_mod); ;} break; case 69: -#line 391 "engines/director/lingo/lingo-gr.y" +#line 392 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(g_lingo->c_gt); ;} break; case 70: -#line 392 "engines/director/lingo/lingo-gr.y" +#line 393 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(g_lingo->c_lt); ;} break; case 71: -#line 393 "engines/director/lingo/lingo-gr.y" +#line 394 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(g_lingo->c_neq); ;} break; case 72: -#line 394 "engines/director/lingo/lingo-gr.y" +#line 395 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(g_lingo->c_ge); ;} break; case 73: -#line 395 "engines/director/lingo/lingo-gr.y" +#line 396 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(g_lingo->c_le); ;} break; case 74: -#line 396 "engines/director/lingo/lingo-gr.y" +#line 397 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(g_lingo->c_and); ;} break; case 75: -#line 397 "engines/director/lingo/lingo-gr.y" +#line 398 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(g_lingo->c_or); ;} break; case 76: -#line 398 "engines/director/lingo/lingo-gr.y" +#line 399 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(g_lingo->c_not); ;} break; case 77: -#line 399 "engines/director/lingo/lingo-gr.y" +#line 400 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(g_lingo->c_ampersand); ;} break; case 78: -#line 400 "engines/director/lingo/lingo-gr.y" +#line 401 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(g_lingo->c_concat); ;} break; case 79: -#line 401 "engines/director/lingo/lingo-gr.y" +#line 402 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(g_lingo->c_contains); ;} break; case 80: -#line 402 "engines/director/lingo/lingo-gr.y" +#line 403 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(g_lingo->c_starts); ;} break; case 81: -#line 403 "engines/director/lingo/lingo-gr.y" +#line 404 "engines/director/lingo/lingo-gr.y" { (yyval.code) = (yyvsp[(2) - (2)].code); ;} break; case 82: -#line 404 "engines/director/lingo/lingo-gr.y" +#line 405 "engines/director/lingo/lingo-gr.y" { (yyval.code) = (yyvsp[(2) - (2)].code); g_lingo->code1(g_lingo->c_negate); ;} break; case 83: -#line 405 "engines/director/lingo/lingo-gr.y" +#line 406 "engines/director/lingo/lingo-gr.y" { (yyval.code) = (yyvsp[(2) - (3)].code); ;} break; case 84: -#line 406 "engines/director/lingo/lingo-gr.y" +#line 407 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(g_lingo->c_intersects); ;} break; case 85: -#line 407 "engines/director/lingo/lingo-gr.y" +#line 408 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(g_lingo->c_within); ;} break; case 86: -#line 410 "engines/director/lingo/lingo-gr.y" +#line 411 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(g_lingo->c_printtop); ;} break; case 89: -#line 413 "engines/director/lingo/lingo-gr.y" +#line 414 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(g_lingo->c_exitRepeat); ;} break; case 90: -#line 414 "engines/director/lingo/lingo-gr.y" +#line 415 "engines/director/lingo/lingo-gr.y" { g_lingo->codeConst(0); // Push fake value on stack g_lingo->code1(g_lingo->c_procret); ;} break; case 93: -#line 418 "engines/director/lingo/lingo-gr.y" +#line 419 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(g_lingo->_handlers[*(yyvsp[(1) - (2)].s)]->u.func); delete (yyvsp[(1) - (2)].s); ;} break; case 94: -#line 421 "engines/director/lingo/lingo-gr.y" +#line 422 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(g_lingo->_handlers[*(yyvsp[(1) - (2)].s)]->u.func); delete (yyvsp[(1) - (2)].s); ;} break; case 95: -#line 424 "engines/director/lingo/lingo-gr.y" +#line 425 "engines/director/lingo/lingo-gr.y" { g_lingo->code2(g_lingo->c_voidpush, g_lingo->_handlers[*(yyvsp[(1) - (1)].s)]->u.func); delete (yyvsp[(1) - (1)].s); ;} break; case 96: -#line 427 "engines/director/lingo/lingo-gr.y" +#line 428 "engines/director/lingo/lingo-gr.y" { g_lingo->codeFunc((yyvsp[(1) - (2)].s), (yyvsp[(2) - (2)].narg)); ;} break; case 97: -#line 428 "engines/director/lingo/lingo-gr.y" +#line 429 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(g_lingo->c_open); ;} break; case 98: -#line 429 "engines/director/lingo/lingo-gr.y" +#line 430 "engines/director/lingo/lingo-gr.y" { g_lingo->code2(g_lingo->c_voidpush, g_lingo->c_open); ;} break; case 99: -#line 432 "engines/director/lingo/lingo-gr.y" +#line 433 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(g_lingo->c_global); g_lingo->codeString((yyvsp[(1) - (1)].s)->c_str()); delete (yyvsp[(1) - (1)].s); ;} break; case 100: -#line 433 "engines/director/lingo/lingo-gr.y" +#line 434 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(g_lingo->c_global); g_lingo->codeString((yyvsp[(3) - (3)].s)->c_str()); delete (yyvsp[(3) - (3)].s); ;} break; case 101: -#line 436 "engines/director/lingo/lingo-gr.y" +#line 437 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(g_lingo->c_instance); g_lingo->codeString((yyvsp[(1) - (1)].s)->c_str()); delete (yyvsp[(1) - (1)].s); ;} break; case 102: -#line 437 "engines/director/lingo/lingo-gr.y" +#line 438 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(g_lingo->c_instance); g_lingo->codeString((yyvsp[(3) - (3)].s)->c_str()); delete (yyvsp[(3) - (3)].s); ;} break; case 103: -#line 448 "engines/director/lingo/lingo-gr.y" +#line 449 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(g_lingo->c_gotoloop); ;} break; case 104: -#line 449 "engines/director/lingo/lingo-gr.y" +#line 450 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(g_lingo->c_gotonext); ;} break; case 105: -#line 450 "engines/director/lingo/lingo-gr.y" +#line 451 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(g_lingo->c_gotoprevious); ;} break; case 106: -#line 451 "engines/director/lingo/lingo-gr.y" +#line 452 "engines/director/lingo/lingo-gr.y" { g_lingo->codeConst(1); g_lingo->code1(g_lingo->c_goto); ;} break; case 107: -#line 454 "engines/director/lingo/lingo-gr.y" +#line 455 "engines/director/lingo/lingo-gr.y" { g_lingo->codeConst(3); g_lingo->code1(g_lingo->c_goto); ;} break; case 108: -#line 457 "engines/director/lingo/lingo-gr.y" +#line 458 "engines/director/lingo/lingo-gr.y" { g_lingo->codeConst(2); g_lingo->code1(g_lingo->c_goto); ;} break; case 113: -#line 470 "engines/director/lingo/lingo-gr.y" +#line 471 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(g_lingo->c_playdone); ;} break; case 114: -#line 471 "engines/director/lingo/lingo-gr.y" +#line 472 "engines/director/lingo/lingo-gr.y" { g_lingo->codeConst(1); g_lingo->code1(g_lingo->c_play); ;} break; case 115: -#line 474 "engines/director/lingo/lingo-gr.y" +#line 475 "engines/director/lingo/lingo-gr.y" { g_lingo->codeConst(3); g_lingo->code1(g_lingo->c_play); ;} break; case 116: -#line 477 "engines/director/lingo/lingo-gr.y" +#line 478 "engines/director/lingo/lingo-gr.y" { g_lingo->codeConst(2); g_lingo->code1(g_lingo->c_play); ;} break; case 117: -#line 507 "engines/director/lingo/lingo-gr.y" +#line 508 "engines/director/lingo/lingo-gr.y" { g_lingo->_indef = true; g_lingo->_currentFactory.clear(); ;} break; case 118: -#line 508 "engines/director/lingo/lingo-gr.y" +#line 509 "engines/director/lingo/lingo-gr.y" { g_lingo->codeConst(0); // Push fake value on stack g_lingo->code1(g_lingo->c_procret); @@ -2518,19 +2550,19 @@ yyreduce: break; case 119: -#line 513 "engines/director/lingo/lingo-gr.y" +#line 514 "engines/director/lingo/lingo-gr.y" { g_lingo->codeFactory(*(yyvsp[(2) - (2)].s)); ;} break; case 120: -#line 516 "engines/director/lingo/lingo-gr.y" +#line 517 "engines/director/lingo/lingo-gr.y" { g_lingo->_indef = true; ;} break; case 121: -#line 517 "engines/director/lingo/lingo-gr.y" +#line 518 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(g_lingo->c_procret); g_lingo->define(*(yyvsp[(2) - (8)].s), (yyvsp[(4) - (8)].code), (yyvsp[(5) - (8)].narg) + 1, &g_lingo->_currentFactory); @@ -2538,32 +2570,60 @@ yyreduce: break; case 122: -#line 521 "engines/director/lingo/lingo-gr.y" - { (yyval.narg) = 0; ;} +#line 522 "engines/director/lingo/lingo-gr.y" + { g_lingo->_indef = true; g_lingo->_currentFactory.clear(); ;} break; case 123: -#line 522 "engines/director/lingo/lingo-gr.y" - { g_lingo->codeArg((yyvsp[(1) - (1)].s)); (yyval.narg) = 1; ;} +#line 523 "engines/director/lingo/lingo-gr.y" + { + g_lingo->codeConst(0); // Push fake value on stack + g_lingo->code1(g_lingo->c_procret); + g_lingo->define(*(yyvsp[(2) - (7)].s), (yyvsp[(4) - (7)].code), 0); + g_lingo->_indef = false; ;} break; case 124: -#line 523 "engines/director/lingo/lingo-gr.y" - { g_lingo->codeArg((yyvsp[(3) - (3)].s)); (yyval.narg) = (yyvsp[(1) - (3)].narg) + 1; ;} +#line 528 "engines/director/lingo/lingo-gr.y" + { g_lingo->_indef = true; g_lingo->_currentFactory.clear(); ;} break; case 125: -#line 524 "engines/director/lingo/lingo-gr.y" - { g_lingo->codeArg((yyvsp[(4) - (4)].s)); (yyval.narg) = (yyvsp[(1) - (4)].narg) + 1; ;} +#line 529 "engines/director/lingo/lingo-gr.y" + { + g_lingo->codeConst(0); // Push fake value on stack + g_lingo->code1(g_lingo->c_procret); + g_lingo->define(*(yyvsp[(2) - (8)].s), (yyvsp[(4) - (8)].code), 0); + g_lingo->_indef = false; ;} break; case 126: -#line 526 "engines/director/lingo/lingo-gr.y" - { g_lingo->codeArgStore(); ;} +#line 535 "engines/director/lingo/lingo-gr.y" + { (yyval.narg) = 0; ;} break; case 127: -#line 530 "engines/director/lingo/lingo-gr.y" +#line 536 "engines/director/lingo/lingo-gr.y" + { g_lingo->codeArg((yyvsp[(1) - (1)].s)); (yyval.narg) = 1; ;} + break; + + case 128: +#line 537 "engines/director/lingo/lingo-gr.y" + { g_lingo->codeArg((yyvsp[(3) - (3)].s)); (yyval.narg) = (yyvsp[(1) - (3)].narg) + 1; ;} + break; + + case 129: +#line 538 "engines/director/lingo/lingo-gr.y" + { g_lingo->codeArg((yyvsp[(4) - (4)].s)); (yyval.narg) = (yyvsp[(1) - (4)].narg) + 1; ;} + break; + + case 130: +#line 540 "engines/director/lingo/lingo-gr.y" + { g_lingo->codeArgStore(); ;} + break; + + case 131: +#line 544 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(g_lingo->c_call); g_lingo->codeString((yyvsp[(1) - (3)].s)->c_str()); @@ -2572,24 +2632,24 @@ yyreduce: g_lingo->code1(numpar); ;} break; - case 128: -#line 538 "engines/director/lingo/lingo-gr.y" + case 132: +#line 552 "engines/director/lingo/lingo-gr.y" { (yyval.narg) = 0; ;} break; - case 129: -#line 539 "engines/director/lingo/lingo-gr.y" + case 133: +#line 553 "engines/director/lingo/lingo-gr.y" { (yyval.narg) = 1; ;} break; - case 130: -#line 540 "engines/director/lingo/lingo-gr.y" + case 134: +#line 554 "engines/director/lingo/lingo-gr.y" { (yyval.narg) = (yyvsp[(1) - (3)].narg) + 1; ;} break; /* Line 1267 of yacc.c. */ -#line 2593 "engines/director/lingo/lingo-gr.cpp" +#line 2653 "engines/director/lingo/lingo-gr.cpp" default: break; } YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc); @@ -2803,6 +2863,6 @@ yyreturn: } -#line 543 "engines/director/lingo/lingo-gr.y" +#line 557 "engines/director/lingo/lingo-gr.y" diff --git a/engines/director/lingo/lingo-gr.h b/engines/director/lingo/lingo-gr.h index 46097085fe..2ebef09e2f 100644 --- a/engines/director/lingo/lingo-gr.h +++ b/engines/director/lingo/lingo-gr.h @@ -107,7 +107,9 @@ tSTARTS = 323, tSPRITE = 324, tINTERSECTS = 325, - tWITHIN = 326 + tWITHIN = 326, + tON = 327, + tME = 328 }; #endif /* Tokens. */ @@ -180,6 +182,8 @@ #define tSPRITE 324 #define tINTERSECTS 325 #define tWITHIN 326 +#define tON 327 +#define tME 328 @@ -197,7 +201,7 @@ typedef union YYSTYPE Common::Array<double> *arr; } /* Line 1529 of yacc.c. */ -#line 201 "engines/director/lingo/lingo-gr.hpp" +#line 205 "engines/director/lingo/lingo-gr.hpp" YYSTYPE; # define yystype YYSTYPE /* obsolescent; will be withdrawn */ # define YYSTYPE_IS_DECLARED 1 diff --git a/engines/director/lingo/lingo-gr.y b/engines/director/lingo/lingo-gr.y index 9077f44876..8e7a60d40e 100644 --- a/engines/director/lingo/lingo-gr.y +++ b/engines/director/lingo/lingo-gr.y @@ -89,6 +89,7 @@ void yyerror(const char *s) { %token tGE tLE tGT tLT tEQ tNEQ tAND tOR tNOT tMOD %token tCONCAT tCONTAINS tSTARTS %token tSPRITE tINTERSECTS tWITHIN +%token tON tME %type<code> asgn begin elseif elsestmtoneliner end expr if when repeatwhile repeatwith stmtlist %type<narg> argdef arglist @@ -518,6 +519,19 @@ defn: tMACRO ID { g_lingo->_indef = true; g_lingo->_currentFactory.clear(); } g_lingo->code1(g_lingo->c_procret); g_lingo->define(*$2, $4, $5 + 1, &g_lingo->_currentFactory); g_lingo->_indef = false; } ; + | tON ID { g_lingo->_indef = true; g_lingo->_currentFactory.clear(); } + begin nl stmtlist tEND { + g_lingo->codeConst(0); // Push fake value on stack + g_lingo->code1(g_lingo->c_procret); + g_lingo->define(*$2, $4, 0); + g_lingo->_indef = false; } + | tON ID { g_lingo->_indef = true; g_lingo->_currentFactory.clear(); } + begin tME nl stmtlist tEND { + g_lingo->codeConst(0); // Push fake value on stack + g_lingo->code1(g_lingo->c_procret); + g_lingo->define(*$2, $4, 0); + g_lingo->_indef = false; } + argdef: /* nothing */ { $$ = 0; } | ID { g_lingo->codeArg($1); $$ = 1; } | argdef ',' ID { g_lingo->codeArg($3); $$ = $1 + 1; } diff --git a/engines/director/lingo/lingo-lex.cpp b/engines/director/lingo/lingo-lex.cpp index 5c0eeedf7e..2bc31335f3 100644 --- a/engines/director/lingo/lingo-lex.cpp +++ b/engines/director/lingo/lingo-lex.cpp @@ -34,7 +34,7 @@ #if defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L /* C99 says to define __STDC_LIMIT_MACROS before including stdint.h, - * if you want the limit (max/min) macros for int types. + * if you want the limit (max/min) macros for int types. */ #ifndef __STDC_LIMIT_MACROS #define __STDC_LIMIT_MACROS 1 @@ -52,7 +52,7 @@ typedef uint64_t flex_uint64_t; typedef signed char flex_int8_t; typedef short int flex_int16_t; typedef int flex_int32_t; -typedef unsigned char flex_uint8_t; +typedef unsigned char flex_uint8_t; typedef unsigned short int flex_uint16_t; typedef unsigned int flex_uint32_t; #endif /* ! C99 */ @@ -168,7 +168,7 @@ extern FILE *yyin, *yyout; #define EOB_ACT_LAST_MATCH 2 #define YY_LESS_LINENO(n) - + /* Return all but the first "n" matched characters back to the input stream. */ #define yyless(n) \ do \ @@ -225,7 +225,7 @@ struct yy_buffer_state int yy_bs_lineno; /**< The line count. */ int yy_bs_column; /**< The column count. */ - + /* Whether to try to fill the input buffer when we reach the * end of it. */ @@ -364,8 +364,8 @@ static void yy_fatal_error (yyconst char msg[] ); *yy_cp = '\0'; \ (yy_c_buf_p) = yy_cp; -#define YY_NUM_RULES 59 -#define YY_END_OF_BUFFER 60 +#define YY_NUM_RULES 61 +#define YY_END_OF_BUFFER 62 /* This struct is not used in this scanner, but its presence is necessary. */ struct yy_trans_info @@ -373,31 +373,31 @@ struct yy_trans_info flex_int32_t yy_verify; flex_int32_t yy_nxt; }; -static yyconst flex_int16_t yy_accept[206] = +static yyconst flex_int16_t yy_accept[207] = { 0, - 0, 0, 60, 58, 3, 56, 56, 58, 58, 55, - 55, 55, 54, 55, 55, 52, 52, 52, 52, 52, - 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, - 52, 52, 2, 2, 3, 56, 0, 0, 0, 0, - 0, 57, 51, 1, 53, 54, 50, 48, 49, 52, - 52, 52, 52, 52, 52, 52, 52, 52, 52, 18, - 8, 52, 52, 52, 52, 52, 52, 52, 29, 52, - 31, 52, 52, 52, 52, 52, 52, 52, 52, 42, - 52, 52, 2, 2, 0, 1, 53, 4, 52, 52, - 52, 52, 12, 52, 52, 52, 52, 0, 52, 52, - - 52, 52, 52, 25, 52, 52, 28, 52, 52, 52, - 34, 52, 36, 52, 52, 52, 52, 52, 52, 0, - 52, 6, 7, 11, 14, 52, 52, 52, 0, 52, - 52, 21, 22, 52, 52, 52, 27, 30, 32, 52, - 52, 52, 52, 0, 41, 46, 52, 44, 10, 52, - 52, 15, 52, 17, 52, 52, 23, 52, 26, 52, - 52, 52, 52, 40, 40, 47, 52, 0, 52, 52, - 16, 52, 52, 24, 52, 35, 43, 37, 0, 40, - 45, 0, 52, 13, 52, 52, 52, 0, 40, 9, - 5, 19, 52, 33, 0, 40, 52, 0, 0, 20, - - 39, 0, 0, 38, 0 + 0, 0, 62, 60, 3, 58, 58, 60, 60, 57, + 57, 57, 56, 57, 57, 54, 54, 54, 54, 54, + 54, 54, 54, 54, 54, 54, 54, 54, 54, 54, + 54, 54, 2, 2, 3, 58, 0, 0, 0, 0, + 0, 59, 53, 1, 55, 56, 52, 50, 51, 54, + 54, 54, 54, 54, 54, 54, 54, 54, 54, 18, + 8, 54, 54, 54, 24, 54, 54, 54, 30, 31, + 54, 33, 54, 54, 54, 54, 54, 54, 54, 54, + 44, 54, 54, 2, 2, 0, 1, 55, 4, 54, + 54, 54, 54, 12, 54, 54, 54, 54, 0, 54, + + 54, 54, 54, 54, 26, 54, 54, 29, 54, 54, + 54, 36, 54, 38, 54, 54, 54, 54, 54, 54, + 0, 54, 6, 7, 11, 14, 54, 54, 54, 0, + 54, 54, 21, 22, 54, 54, 54, 28, 32, 34, + 54, 54, 54, 54, 0, 43, 48, 54, 46, 10, + 54, 54, 15, 54, 17, 54, 54, 23, 54, 27, + 54, 54, 54, 54, 42, 42, 49, 54, 0, 54, + 54, 16, 54, 54, 25, 54, 37, 45, 39, 0, + 42, 47, 0, 54, 13, 54, 54, 54, 0, 42, + 9, 5, 19, 54, 35, 0, 42, 54, 0, 0, + + 20, 41, 0, 0, 40, 0 } ; static yyconst flex_int32_t yy_ec[256] = @@ -443,61 +443,63 @@ static yyconst flex_int32_t yy_meta[63] = 5, 5 } ; -static yyconst flex_int16_t yy_base[211] = +static yyconst flex_int16_t yy_base[212] = { 0, - 0, 61, 156, 521, 65, 69, 73, 77, 148, 521, - 104, 99, 54, 70, 91, 58, 0, 58, 59, 69, - 74, 70, 70, 71, 88, 105, 105, 110, 82, 118, - 117, 130, 177, 181, 185, 521, 189, 193, 197, 106, - 94, 521, 521, 0, 82, 132, 521, 521, 521, 0, - 84, 119, 169, 116, 120, 174, 186, 191, 180, 171, - 0, 177, 183, 196, 182, 201, 181, 188, 0, 204, - 0, 209, 206, 194, 201, 207, 212, 231, 228, 0, - 233, 222, 271, 280, 230, 0, 80, 0, 230, 234, - 238, 247, 0, 235, 236, 244, 264, 293, 255, 271, - - 267, 266, 278, 0, 279, 271, 0, 279, 269, 273, - 0, 290, 0, 287, 282, 309, 289, 292, 296, 300, - 307, 0, 0, 0, 0, 296, 310, 318, 310, 324, - 311, 0, 0, 317, 318, 330, 0, 0, 0, 328, - 337, 322, 323, 363, 0, 0, 334, 334, 202, 336, - 330, 0, 338, 521, 340, 340, 0, 355, 0, 347, - 348, 364, 354, 212, 387, 0, 361, 388, 367, 359, - 0, 383, 382, 0, 369, 0, 0, 0, 402, 404, - 0, 393, 383, 0, 401, 405, 384, 403, 427, 521, - 0, 0, 395, 0, 256, 429, 401, 441, 448, 0, - - 453, 404, 459, 460, 521, 500, 502, 507, 511, 515 + 0, 61, 155, 520, 65, 69, 73, 77, 148, 520, + 140, 130, 54, 70, 99, 58, 0, 58, 59, 69, + 74, 70, 70, 71, 88, 105, 107, 110, 81, 134, + 109, 123, 170, 177, 181, 520, 190, 145, 194, 77, + 102, 520, 520, 0, 82, 132, 520, 520, 520, 0, + 133, 139, 173, 145, 184, 180, 187, 190, 160, 99, + 0, 175, 182, 194, 182, 200, 179, 184, 0, 0, + 200, 0, 205, 202, 190, 196, 193, 206, 227, 229, + 0, 232, 220, 260, 266, 222, 0, 80, 0, 224, + 239, 233, 247, 0, 239, 241, 249, 263, 280, 253, + + 273, 258, 257, 267, 0, 267, 261, 0, 268, 259, + 265, 0, 283, 0, 280, 274, 304, 281, 291, 298, + 303, 308, 0, 0, 0, 0, 298, 314, 319, 302, + 320, 307, 0, 0, 311, 313, 317, 0, 0, 0, + 319, 328, 313, 316, 351, 0, 0, 325, 328, 369, + 329, 326, 0, 339, 520, 339, 340, 0, 357, 0, + 350, 346, 361, 350, 382, 384, 0, 358, 389, 365, + 355, 0, 378, 378, 0, 365, 0, 0, 0, 396, + 408, 0, 384, 376, 0, 392, 398, 386, 399, 423, + 520, 0, 0, 388, 0, 425, 429, 394, 441, 447, + + 0, 449, 413, 455, 457, 520, 499, 501, 506, 510, + 514 } ; -static yyconst flex_int16_t yy_def[211] = +static yyconst flex_int16_t yy_def[212] = { 0, - 205, 1, 205, 205, 205, 205, 205, 205, 206, 205, - 205, 205, 205, 205, 205, 207, 207, 207, 207, 207, - 207, 207, 207, 207, 207, 207, 207, 207, 207, 207, - 207, 207, 205, 205, 205, 205, 205, 205, 205, 205, - 206, 205, 205, 208, 205, 205, 205, 205, 205, 207, - 207, 207, 207, 207, 207, 207, 207, 207, 207, 207, - 207, 207, 207, 207, 207, 207, 207, 207, 207, 207, - 207, 207, 207, 207, 207, 207, 207, 207, 207, 207, - 207, 207, 205, 205, 205, 208, 205, 207, 207, 207, - 207, 207, 207, 207, 207, 207, 207, 205, 207, 207, - - 207, 207, 207, 207, 207, 207, 207, 207, 207, 207, - 207, 207, 207, 207, 207, 207, 207, 207, 207, 205, - 207, 207, 207, 207, 207, 207, 207, 207, 205, 207, - 207, 207, 207, 207, 207, 207, 207, 207, 207, 207, - 207, 207, 207, 209, 207, 207, 207, 207, 205, 207, - 207, 207, 207, 205, 207, 207, 207, 207, 207, 207, - 207, 207, 207, 209, 209, 207, 207, 205, 207, 207, - 207, 207, 207, 207, 207, 207, 207, 207, 205, 209, - 207, 205, 207, 207, 207, 207, 207, 205, 209, 205, - 207, 207, 207, 207, 205, 209, 207, 210, 205, 207, - - 210, 205, 205, 210, 0, 205, 205, 205, 205, 205 + 206, 1, 206, 206, 206, 206, 206, 206, 207, 206, + 206, 206, 206, 206, 206, 208, 208, 208, 208, 208, + 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, + 208, 208, 206, 206, 206, 206, 206, 206, 206, 206, + 207, 206, 206, 209, 206, 206, 206, 206, 206, 208, + 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, + 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, + 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, + 208, 208, 208, 206, 206, 206, 209, 206, 208, 208, + 208, 208, 208, 208, 208, 208, 208, 208, 206, 208, + + 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, + 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, + 206, 208, 208, 208, 208, 208, 208, 208, 208, 206, + 208, 208, 208, 208, 208, 208, 208, 208, 208, 208, + 208, 208, 208, 208, 210, 208, 208, 208, 208, 206, + 208, 208, 208, 208, 206, 208, 208, 208, 208, 208, + 208, 208, 208, 208, 210, 210, 208, 208, 206, 208, + 208, 208, 208, 208, 208, 208, 208, 208, 208, 206, + 210, 208, 206, 208, 208, 208, 208, 208, 206, 210, + 206, 208, 208, 208, 208, 206, 210, 208, 211, 206, + + 208, 211, 206, 206, 211, 0, 206, 206, 206, 206, + 206 } ; -static yyconst flex_int16_t yy_nxt[584] = +static yyconst flex_int16_t yy_nxt[583] = { 0, 4, 5, 6, 7, 8, 9, 10, 11, 12, 4, 13, 14, 10, 15, 16, 17, 18, 19, 20, 21, @@ -508,64 +510,64 @@ static yyconst flex_int16_t yy_nxt[584] = 17, 17, 33, 45, 46, 34, 35, 36, 36, 37, 38, 39, 39, 38, 38, 39, 39, 38, 37, 36, 36, 37, 47, 48, 51, 52, 53, 40, 57, 61, - 87, 40, 87, 54, 59, 55, 62, 60, 63, 42, - - 75, 88, 64, 49, 58, 56, 65, 44, 51, 52, - 53, 43, 40, 57, 61, 66, 40, 54, 59, 55, - 62, 60, 63, 67, 69, 75, 88, 64, 58, 56, - 85, 65, 68, 70, 72, 71, 76, 93, 79, 66, - 73, 45, 46, 74, 80, 89, 77, 92, 67, 69, - 78, 81, 82, 42, 85, 205, 68, 70, 72, 71, - 205, 76, 93, 79, 73, 205, 205, 74, 80, 89, - 77, 92, 98, 205, 78, 98, 81, 82, 83, 36, - 36, 84, 84, 36, 36, 84, 35, 36, 36, 37, - 37, 36, 36, 37, 38, 90, 94, 38, 38, 39, - - 39, 38, 95, 168, 91, 96, 168, 97, 99, 100, - 101, 40, 102, 179, 103, 40, 179, 106, 104, 90, - 107, 94, 108, 109, 110, 205, 111, 95, 91, 112, - 96, 97, 99, 100, 101, 105, 40, 102, 103, 113, - 40, 106, 114, 104, 107, 115, 116, 108, 109, 110, - 111, 117, 122, 112, 119, 118, 205, 198, 205, 105, - 198, 120, 121, 113, 123, 124, 114, 125, 126, 127, - 115, 116, 83, 36, 36, 84, 117, 122, 119, 128, - 118, 84, 36, 36, 84, 120, 121, 130, 123, 131, - 124, 125, 126, 127, 98, 133, 134, 98, 132, 135, - - 205, 136, 205, 137, 128, 138, 139, 140, 141, 142, - 144, 130, 143, 144, 131, 146, 147, 148, 149, 133, - 134, 150, 132, 151, 135, 129, 136, 137, 152, 138, - 139, 140, 153, 141, 142, 145, 143, 154, 155, 146, - 147, 156, 148, 149, 157, 158, 150, 151, 159, 129, - 160, 161, 166, 152, 162, 163, 167, 153, 169, 145, - 170, 154, 171, 155, 144, 156, 172, 144, 157, 158, - 205, 173, 174, 159, 175, 160, 161, 166, 162, 163, - 176, 167, 177, 169, 170, 178, 171, 181, 179, 168, - 172, 179, 168, 183, 165, 173, 184, 174, 175, 185, - - 186, 205, 187, 179, 176, 179, 179, 177, 179, 178, - 182, 181, 190, 205, 191, 194, 180, 183, 165, 192, - 184, 193, 195, 203, 185, 186, 187, 197, 179, 188, - 199, 179, 200, 199, 189, 182, 205, 190, 191, 194, - 180, 205, 198, 205, 192, 198, 193, 195, 203, 199, - 205, 197, 199, 188, 205, 205, 200, 205, 189, 196, - 204, 204, 205, 204, 204, 205, 205, 205, 205, 205, - 205, 205, 205, 205, 205, 202, 205, 205, 205, 205, - 205, 205, 205, 196, 205, 205, 205, 205, 205, 205, - 205, 205, 205, 205, 205, 205, 205, 205, 205, 202, - - 41, 41, 205, 41, 41, 50, 50, 86, 86, 205, - 86, 86, 164, 205, 205, 164, 201, 205, 205, 201, - 3, 205, 205, 205, 205, 205, 205, 205, 205, 205, - 205, 205, 205, 205, 205, 205, 205, 205, 205, 205, - 205, 205, 205, 205, 205, 205, 205, 205, 205, 205, - 205, 205, 205, 205, 205, 205, 205, 205, 205, 205, - 205, 205, 205, 205, 205, 205, 205, 205, 205, 205, - 205, 205, 205, 205, 205, 205, 205, 205, 205, 205, - 205, 205, 205 + 88, 40, 88, 54, 59, 55, 62, 60, 63, 76, + + 99, 86, 64, 99, 58, 56, 65, 42, 51, 52, + 53, 49, 40, 57, 61, 66, 40, 54, 59, 55, + 62, 60, 63, 67, 76, 86, 69, 64, 58, 56, + 80, 65, 68, 70, 73, 71, 81, 72, 44, 66, + 74, 45, 46, 75, 82, 83, 38, 43, 67, 38, + 89, 69, 77, 42, 206, 80, 68, 70, 73, 71, + 81, 72, 78, 40, 74, 90, 79, 75, 206, 82, + 83, 84, 36, 36, 85, 89, 93, 77, 85, 36, + 36, 85, 35, 36, 36, 37, 78, 98, 40, 90, + 79, 37, 36, 36, 37, 38, 39, 39, 38, 91, + + 93, 94, 95, 96, 97, 206, 100, 101, 92, 102, + 103, 98, 40, 206, 104, 107, 108, 105, 109, 110, + 111, 206, 112, 91, 113, 114, 94, 95, 96, 97, + 100, 101, 92, 102, 106, 103, 115, 40, 104, 107, + 108, 116, 105, 109, 110, 111, 112, 117, 113, 114, + 118, 206, 120, 121, 119, 206, 122, 123, 106, 124, + 115, 84, 36, 36, 85, 125, 116, 85, 36, 36, + 85, 126, 117, 127, 128, 118, 120, 121, 129, 119, + 122, 99, 123, 124, 99, 131, 134, 135, 136, 137, + 125, 132, 206, 138, 139, 126, 140, 127, 128, 141, + + 133, 142, 143, 129, 144, 145, 206, 147, 145, 131, + 134, 135, 130, 136, 137, 148, 132, 138, 139, 149, + 140, 150, 151, 141, 133, 152, 142, 143, 144, 155, + 146, 147, 153, 154, 156, 160, 130, 157, 158, 148, + 159, 161, 162, 167, 149, 163, 150, 151, 164, 152, + 168, 170, 145, 155, 146, 145, 171, 153, 154, 156, + 160, 157, 158, 172, 159, 173, 161, 162, 167, 163, + 169, 174, 164, 169, 175, 168, 170, 176, 177, 178, + 171, 179, 166, 180, 182, 180, 180, 172, 180, 173, + 169, 184, 185, 169, 186, 174, 187, 180, 188, 175, + + 180, 176, 177, 191, 178, 179, 166, 192, 182, 180, + 193, 183, 180, 181, 194, 184, 185, 195, 196, 186, + 198, 187, 188, 189, 180, 201, 199, 180, 191, 199, + 200, 192, 204, 200, 206, 193, 183, 181, 190, 194, + 206, 195, 199, 196, 198, 199, 206, 189, 200, 201, + 206, 200, 206, 206, 206, 197, 205, 204, 205, 205, + 206, 205, 190, 206, 206, 206, 206, 206, 206, 206, + 206, 206, 206, 206, 203, 206, 206, 206, 206, 197, + 206, 206, 206, 206, 206, 206, 206, 206, 206, 206, + 206, 206, 206, 206, 206, 206, 206, 206, 203, 41, + + 41, 206, 41, 41, 50, 50, 87, 87, 206, 87, + 87, 165, 206, 206, 165, 202, 206, 206, 202, 3, + 206, 206, 206, 206, 206, 206, 206, 206, 206, 206, + 206, 206, 206, 206, 206, 206, 206, 206, 206, 206, + 206, 206, 206, 206, 206, 206, 206, 206, 206, 206, + 206, 206, 206, 206, 206, 206, 206, 206, 206, 206, + 206, 206, 206, 206, 206, 206, 206, 206, 206, 206, + 206, 206, 206, 206, 206, 206, 206, 206, 206, 206, + 206, 206 } ; -static yyconst flex_int16_t yy_chk[584] = +static yyconst flex_int16_t yy_chk[583] = { 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, @@ -576,61 +578,61 @@ static yyconst flex_int16_t yy_chk[584] = 1, 1, 2, 13, 13, 2, 5, 5, 5, 5, 6, 6, 6, 6, 7, 7, 7, 7, 8, 8, 8, 8, 14, 14, 16, 18, 19, 6, 21, 23, - 87, 7, 45, 20, 22, 20, 23, 22, 24, 41, - - 29, 51, 25, 15, 21, 20, 25, 12, 16, 18, - 19, 11, 6, 21, 23, 25, 7, 20, 22, 20, - 23, 22, 24, 26, 27, 29, 51, 25, 21, 20, - 40, 25, 26, 27, 28, 27, 30, 55, 31, 25, - 28, 46, 46, 28, 31, 52, 30, 54, 26, 27, - 30, 32, 32, 9, 40, 3, 26, 27, 28, 27, - 0, 30, 55, 31, 28, 0, 0, 28, 31, 52, - 30, 54, 60, 0, 30, 60, 32, 32, 33, 33, - 33, 33, 34, 34, 34, 34, 35, 35, 35, 35, - 37, 37, 37, 37, 38, 53, 56, 38, 39, 39, - - 39, 39, 57, 149, 53, 58, 149, 59, 62, 62, - 63, 38, 64, 164, 65, 39, 164, 67, 66, 53, - 68, 56, 70, 72, 73, 0, 74, 57, 53, 75, - 58, 59, 62, 62, 63, 66, 38, 64, 65, 76, - 39, 67, 77, 66, 68, 78, 79, 70, 72, 73, - 74, 81, 90, 75, 82, 81, 0, 195, 0, 66, - 195, 85, 89, 76, 91, 92, 77, 94, 95, 96, - 78, 79, 83, 83, 83, 83, 81, 90, 82, 97, - 81, 84, 84, 84, 84, 85, 89, 99, 91, 100, - 92, 94, 95, 96, 98, 101, 102, 98, 100, 103, - - 0, 105, 0, 106, 97, 108, 109, 110, 112, 114, - 116, 99, 115, 116, 100, 117, 118, 119, 120, 101, - 102, 121, 100, 126, 103, 98, 105, 106, 127, 108, - 109, 110, 128, 112, 114, 116, 115, 129, 130, 117, - 118, 131, 119, 120, 134, 135, 121, 126, 136, 98, - 140, 141, 147, 127, 142, 143, 148, 128, 150, 116, - 151, 129, 153, 130, 144, 131, 155, 144, 134, 135, - 0, 156, 158, 136, 160, 140, 141, 147, 142, 143, - 161, 148, 162, 150, 151, 163, 153, 167, 165, 168, - 155, 165, 168, 169, 144, 156, 170, 158, 160, 172, - - 173, 0, 175, 179, 161, 180, 179, 162, 180, 163, - 168, 167, 182, 0, 183, 187, 165, 169, 144, 185, - 170, 186, 188, 202, 172, 173, 175, 193, 189, 179, - 196, 189, 197, 196, 180, 168, 0, 182, 183, 187, - 165, 0, 198, 0, 185, 198, 186, 188, 202, 199, - 0, 193, 199, 179, 201, 0, 197, 201, 180, 189, - 203, 204, 0, 203, 204, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 199, 0, 0, 0, 0, - 0, 0, 0, 189, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 199, - - 206, 206, 0, 206, 206, 207, 207, 208, 208, 0, - 208, 208, 209, 0, 0, 209, 210, 0, 0, 210, - 205, 205, 205, 205, 205, 205, 205, 205, 205, 205, - 205, 205, 205, 205, 205, 205, 205, 205, 205, 205, - 205, 205, 205, 205, 205, 205, 205, 205, 205, 205, - 205, 205, 205, 205, 205, 205, 205, 205, 205, 205, - 205, 205, 205, 205, 205, 205, 205, 205, 205, 205, - 205, 205, 205, 205, 205, 205, 205, 205, 205, 205, - 205, 205, 205 + 88, 7, 45, 20, 22, 20, 23, 22, 24, 29, + + 60, 40, 25, 60, 21, 20, 25, 41, 16, 18, + 19, 15, 6, 21, 23, 25, 7, 20, 22, 20, + 23, 22, 24, 26, 29, 40, 27, 25, 21, 20, + 31, 25, 26, 27, 28, 27, 31, 27, 12, 25, + 28, 46, 46, 28, 32, 32, 38, 11, 26, 38, + 51, 27, 30, 9, 3, 31, 26, 27, 28, 27, + 31, 27, 30, 38, 28, 52, 30, 28, 0, 32, + 32, 33, 33, 33, 33, 51, 54, 30, 34, 34, + 34, 34, 35, 35, 35, 35, 30, 59, 38, 52, + 30, 37, 37, 37, 37, 39, 39, 39, 39, 53, + + 54, 55, 56, 57, 58, 0, 62, 62, 53, 63, + 64, 59, 39, 0, 65, 67, 68, 66, 71, 73, + 74, 0, 75, 53, 76, 77, 55, 56, 57, 58, + 62, 62, 53, 63, 66, 64, 78, 39, 65, 67, + 68, 79, 66, 71, 73, 74, 75, 80, 76, 77, + 82, 0, 83, 86, 82, 0, 90, 91, 66, 92, + 78, 84, 84, 84, 84, 93, 79, 85, 85, 85, + 85, 95, 80, 96, 97, 82, 83, 86, 98, 82, + 90, 99, 91, 92, 99, 100, 102, 103, 104, 106, + 93, 101, 0, 107, 109, 95, 110, 96, 97, 111, + + 101, 113, 115, 98, 116, 117, 0, 118, 117, 100, + 102, 103, 99, 104, 106, 119, 101, 107, 109, 120, + 110, 121, 122, 111, 101, 127, 113, 115, 116, 130, + 117, 118, 128, 129, 131, 137, 99, 132, 135, 119, + 136, 141, 142, 148, 120, 143, 121, 122, 144, 127, + 149, 151, 145, 130, 117, 145, 152, 128, 129, 131, + 137, 132, 135, 154, 136, 156, 141, 142, 148, 143, + 150, 157, 144, 150, 159, 149, 151, 161, 162, 163, + 152, 164, 145, 165, 168, 166, 165, 154, 166, 156, + 169, 170, 171, 169, 173, 157, 174, 180, 176, 159, + + 180, 161, 162, 183, 163, 164, 145, 184, 168, 181, + 186, 169, 181, 166, 187, 170, 171, 188, 189, 173, + 194, 174, 176, 180, 190, 198, 196, 190, 183, 196, + 197, 184, 203, 197, 0, 186, 169, 166, 181, 187, + 0, 188, 199, 189, 194, 199, 0, 180, 200, 198, + 202, 200, 0, 202, 0, 190, 204, 203, 205, 204, + 0, 205, 181, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 200, 0, 0, 0, 0, 190, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 200, 207, + + 207, 0, 207, 207, 208, 208, 209, 209, 0, 209, + 209, 210, 0, 0, 210, 211, 0, 0, 211, 206, + 206, 206, 206, 206, 206, 206, 206, 206, 206, 206, + 206, 206, 206, 206, 206, 206, 206, 206, 206, 206, + 206, 206, 206, 206, 206, 206, 206, 206, 206, 206, + 206, 206, 206, 206, 206, 206, 206, 206, 206, 206, + 206, 206, 206, 206, 206, 206, 206, 206, 206, 206, + 206, 206, 206, 206, 206, 206, 206, 206, 206, 206, + 206, 206 } ; static yy_state_type yy_last_accepting_state; @@ -685,12 +687,12 @@ static void count() { g_lingo->_colnumber += strlen(yytext); } -#if defined(__PLAYSTATION2__) || defined(_MSC_VER) || defined(__DC__) +#if defined(__PLAYSTATION2__) || defined(_MSC_VER) // Stub for missing function int isatty(int fileno) { return 0; } #endif -#if defined(_MSC_VER) || defined(__DC__) +#ifdef _MSC_VER #define YY_NO_UNISTD_H #endif @@ -704,7 +706,7 @@ static void countnl() { g_lingo->_colnumber = strlen(p); } -#line 708 "engines/director/lingo/lingo-lex.cpp" +#line 710 "engines/director/lingo/lingo-lex.cpp" #define INITIAL 0 @@ -764,7 +766,7 @@ extern int yywrap (void ); #endif static void yyunput (int c,char *buf_ptr ); - + #ifndef yytext_ptr static void yy_flex_strncpy (char *,yyconst char *,int ); #endif @@ -888,11 +890,11 @@ YY_DECL register yy_state_type yy_current_state; register char *yy_cp, *yy_bp; register int yy_act; - + #line 69 "engines/director/lingo/lingo-lex.l" -#line 896 "engines/director/lingo/lingo-lex.cpp" +#line 898 "engines/director/lingo/lingo-lex.cpp" if ( !(yy_init) ) { @@ -946,13 +948,13 @@ yy_match: while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state ) { yy_current_state = (int) yy_def[yy_current_state]; - if ( yy_current_state >= 206 ) + if ( yy_current_state >= 207 ) yy_c = yy_meta[(unsigned int) yy_c]; } yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c]; ++yy_cp; } - while ( yy_base[yy_current_state] != 521 ); + while ( yy_base[yy_current_state] != 520 ); yy_find_action: yy_act = yy_accept[yy_current_state]; @@ -1096,76 +1098,86 @@ YY_RULE_SETUP case 24: YY_RULE_SETUP #line 95 "engines/director/lingo/lingo-lex.l" -{ count(); return tMETHOD; } +{ count(); return tME; } YY_BREAK case 25: YY_RULE_SETUP #line 96 "engines/director/lingo/lingo-lex.l" -{ count(); return tMOD; } +{ count(); return tMETHOD; } YY_BREAK case 26: YY_RULE_SETUP #line 97 "engines/director/lingo/lingo-lex.l" -{ count(); return tMOVIE; } +{ count(); return tMOD; } YY_BREAK case 27: YY_RULE_SETUP #line 98 "engines/director/lingo/lingo-lex.l" -{ count(); return tNEXT; } +{ count(); return tMOVIE; } YY_BREAK case 28: YY_RULE_SETUP #line 99 "engines/director/lingo/lingo-lex.l" -{ count(); return tNOT; } +{ count(); return tNEXT; } YY_BREAK case 29: YY_RULE_SETUP #line 100 "engines/director/lingo/lingo-lex.l" -{ count(); return tOF; } +{ count(); return tNOT; } YY_BREAK case 30: YY_RULE_SETUP #line 101 "engines/director/lingo/lingo-lex.l" -{ count(); return tOPEN; } +{ count(); return tOF; } YY_BREAK case 31: YY_RULE_SETUP #line 102 "engines/director/lingo/lingo-lex.l" -{ count(); return tOR; } +{ count(); return tON; } YY_BREAK case 32: YY_RULE_SETUP #line 103 "engines/director/lingo/lingo-lex.l" -{ count(); return tPLAY; } +{ count(); return tOPEN; } YY_BREAK case 33: YY_RULE_SETUP #line 104 "engines/director/lingo/lingo-lex.l" -{ count(); return tPREVIOUS; } +{ count(); return tOR; } YY_BREAK case 34: YY_RULE_SETUP #line 105 "engines/director/lingo/lingo-lex.l" -{ count(); return tPUT; } +{ count(); return tPLAY; } YY_BREAK case 35: YY_RULE_SETUP #line 106 "engines/director/lingo/lingo-lex.l" -{ count(); return tREPEAT; } +{ count(); return tPREVIOUS; } YY_BREAK case 36: YY_RULE_SETUP #line 107 "engines/director/lingo/lingo-lex.l" -{ count(); return tSET; } +{ count(); return tPUT; } YY_BREAK case 37: YY_RULE_SETUP #line 108 "engines/director/lingo/lingo-lex.l" -{ count(); return tSTARTS; } +{ count(); return tREPEAT; } YY_BREAK case 38: YY_RULE_SETUP #line 109 "engines/director/lingo/lingo-lex.l" +{ count(); return tSET; } + YY_BREAK +case 39: +YY_RULE_SETUP +#line 110 "engines/director/lingo/lingo-lex.l" +{ count(); return tSTARTS; } + YY_BREAK +case 40: +YY_RULE_SETUP +#line 111 "engines/director/lingo/lingo-lex.l" { count(); @@ -1175,9 +1187,9 @@ YY_RULE_SETUP return THEENTITYWITHID; } YY_BREAK -case 39: +case 41: YY_RULE_SETUP -#line 117 "engines/director/lingo/lingo-lex.l" +#line 119 "engines/director/lingo/lingo-lex.l" { count(); @@ -1219,9 +1231,9 @@ YY_RULE_SETUP warning("Unhandled the entity %s", ptr); } YY_BREAK -case 40: +case 42: YY_RULE_SETUP -#line 157 "engines/director/lingo/lingo-lex.l" +#line 159 "engines/director/lingo/lingo-lex.l" { count(); @@ -1242,64 +1254,64 @@ YY_RULE_SETUP warning("Unhandled the entity %s", ptr); } YY_BREAK -case 41: -YY_RULE_SETUP -#line 176 "engines/director/lingo/lingo-lex.l" -{ count(); return tTHEN; } - YY_BREAK -case 42: -YY_RULE_SETUP -#line 177 "engines/director/lingo/lingo-lex.l" -{ count(); return tTO; } - YY_BREAK case 43: YY_RULE_SETUP #line 178 "engines/director/lingo/lingo-lex.l" -{ count(); return tSPRITE; } +{ count(); return tTHEN; } YY_BREAK case 44: YY_RULE_SETUP #line 179 "engines/director/lingo/lingo-lex.l" -{ count(); return tWITH; } +{ count(); return tTO; } YY_BREAK case 45: YY_RULE_SETUP #line 180 "engines/director/lingo/lingo-lex.l" -{ count(); return tWITHIN; } +{ count(); return tSPRITE; } YY_BREAK case 46: YY_RULE_SETUP #line 181 "engines/director/lingo/lingo-lex.l" -{ count(); return tWHEN; } +{ count(); return tWITH; } YY_BREAK case 47: YY_RULE_SETUP #line 182 "engines/director/lingo/lingo-lex.l" -{ count(); return tWHILE; } +{ count(); return tWITHIN; } YY_BREAK case 48: YY_RULE_SETUP -#line 184 "engines/director/lingo/lingo-lex.l" -{ count(); return tNEQ; } +#line 183 "engines/director/lingo/lingo-lex.l" +{ count(); return tWHEN; } YY_BREAK case 49: YY_RULE_SETUP -#line 185 "engines/director/lingo/lingo-lex.l" -{ count(); return tGE; } +#line 184 "engines/director/lingo/lingo-lex.l" +{ count(); return tWHILE; } YY_BREAK case 50: YY_RULE_SETUP #line 186 "engines/director/lingo/lingo-lex.l" -{ count(); return tLE; } +{ count(); return tNEQ; } YY_BREAK case 51: YY_RULE_SETUP #line 187 "engines/director/lingo/lingo-lex.l" -{ count(); return tCONCAT; } +{ count(); return tGE; } YY_BREAK case 52: YY_RULE_SETUP +#line 188 "engines/director/lingo/lingo-lex.l" +{ count(); return tLE; } + YY_BREAK +case 53: +YY_RULE_SETUP #line 189 "engines/director/lingo/lingo-lex.l" +{ count(); return tCONCAT; } + YY_BREAK +case 54: +YY_RULE_SETUP +#line 191 "engines/director/lingo/lingo-lex.l" { count(); yylval.s = new Common::String(yytext); @@ -1327,43 +1339,43 @@ YY_RULE_SETUP return ID; } YY_BREAK -case 53: -YY_RULE_SETUP -#line 215 "engines/director/lingo/lingo-lex.l" -{ count(); yylval.f = atof(yytext); return FLOAT; } - YY_BREAK -case 54: -YY_RULE_SETUP -#line 216 "engines/director/lingo/lingo-lex.l" -{ count(); yylval.i = strtol(yytext, NULL, 10); return INT; } - YY_BREAK case 55: YY_RULE_SETUP #line 217 "engines/director/lingo/lingo-lex.l" -{ count(); return *yytext; } +{ count(); yylval.f = atof(yytext); return FLOAT; } YY_BREAK case 56: -/* rule 56 can match eol */ YY_RULE_SETUP #line 218 "engines/director/lingo/lingo-lex.l" -{ return '\n'; } +{ count(); yylval.i = strtol(yytext, NULL, 10); return INT; } YY_BREAK case 57: YY_RULE_SETUP #line 219 "engines/director/lingo/lingo-lex.l" -{ count(); yylval.s = new Common::String(&yytext[1]); yylval.s->deleteLastChar(); return STRING; } +{ count(); return *yytext; } YY_BREAK case 58: +/* rule 58 can match eol */ YY_RULE_SETUP #line 220 "engines/director/lingo/lingo-lex.l" - +{ return '\n'; } YY_BREAK case 59: YY_RULE_SETUP +#line 221 "engines/director/lingo/lingo-lex.l" +{ count(); yylval.s = new Common::String(&yytext[1]); yylval.s->deleteLastChar(); return STRING; } + YY_BREAK +case 60: +YY_RULE_SETUP #line 222 "engines/director/lingo/lingo-lex.l" + + YY_BREAK +case 61: +YY_RULE_SETUP +#line 224 "engines/director/lingo/lingo-lex.l" ECHO; YY_BREAK -#line 1367 "engines/director/lingo/lingo-lex.cpp" +#line 1379 "engines/director/lingo/lingo-lex.cpp" case YY_STATE_EOF(INITIAL): yyterminate(); @@ -1641,7 +1653,7 @@ static int yy_get_next_buffer (void) { register yy_state_type yy_current_state; register char *yy_cp; - + yy_current_state = (yy_start); yy_current_state += YY_AT_BOL(); @@ -1656,7 +1668,7 @@ static int yy_get_next_buffer (void) while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state ) { yy_current_state = (int) yy_def[yy_current_state]; - if ( yy_current_state >= 206 ) + if ( yy_current_state >= 207 ) yy_c = yy_meta[(unsigned int) yy_c]; } yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c]; @@ -1684,11 +1696,11 @@ static int yy_get_next_buffer (void) while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state ) { yy_current_state = (int) yy_def[yy_current_state]; - if ( yy_current_state >= 206 ) + if ( yy_current_state >= 207 ) yy_c = yy_meta[(unsigned int) yy_c]; } yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c]; - yy_is_jam = (yy_current_state == 205); + yy_is_jam = (yy_current_state == 206); return yy_is_jam ? 0 : yy_current_state; } @@ -1696,7 +1708,7 @@ static int yy_get_next_buffer (void) static void yyunput (int c, register char * yy_bp ) { register char *yy_cp; - + yy_cp = (yy_c_buf_p); /* undo effects of setting up yytext */ @@ -1739,7 +1751,7 @@ static int yy_get_next_buffer (void) { int c; - + *(yy_c_buf_p) = (yy_hold_char); if ( *(yy_c_buf_p) == YY_END_OF_BUFFER_CHAR ) @@ -1808,12 +1820,12 @@ static int yy_get_next_buffer (void) /** Immediately switch to a different input stream. * @param input_file A readable stream. - * + * * @note This function does not reset the start condition to @c INITIAL . */ void yyrestart (FILE * input_file ) { - + if ( ! YY_CURRENT_BUFFER ){ yyensure_buffer_stack (); YY_CURRENT_BUFFER_LVALUE = @@ -1826,11 +1838,11 @@ static int yy_get_next_buffer (void) /** Switch to a different input buffer. * @param new_buffer The new input buffer. - * + * */ void yy_switch_to_buffer (YY_BUFFER_STATE new_buffer ) { - + /* TODO. We should be able to replace this entire function body * with * yypop_buffer_state(); @@ -1870,13 +1882,13 @@ static void yy_load_buffer_state (void) /** Allocate and initialize an input buffer state. * @param file A readable stream. * @param size The character buffer size in bytes. When in doubt, use @c YY_BUF_SIZE. - * + * * @return the allocated buffer state. */ YY_BUFFER_STATE yy_create_buffer (FILE * file, int size ) { YY_BUFFER_STATE b; - + b = (YY_BUFFER_STATE) yyalloc(sizeof( struct yy_buffer_state ) ); if ( ! b ) YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" ); @@ -1899,11 +1911,11 @@ static void yy_load_buffer_state (void) /** Destroy the buffer. * @param b a buffer created with yy_create_buffer() - * + * */ void yy_delete_buffer (YY_BUFFER_STATE b ) { - + if ( ! b ) return; @@ -1919,7 +1931,7 @@ static void yy_load_buffer_state (void) #ifndef __cplusplus extern int isatty (int ); #endif /* __cplusplus */ - + /* Initializes or reinitializes a buffer. * This function is sometimes called more than once on the same buffer, * such as during a yyrestart() or at EOF. @@ -1928,7 +1940,7 @@ extern int isatty (int ); { int oerrno = errno; - + yy_flush_buffer(b ); b->yy_input_file = file; @@ -1944,13 +1956,13 @@ extern int isatty (int ); } b->yy_is_interactive = file ? (isatty( fileno(file) ) > 0) : 0; - + errno = oerrno; } /** Discard all buffered characters. On the next scan, YY_INPUT will be called. * @param b the buffer state to be flushed, usually @c YY_CURRENT_BUFFER. - * + * */ void yy_flush_buffer (YY_BUFFER_STATE b ) { @@ -1979,7 +1991,7 @@ extern int isatty (int ); * the current state. This function will allocate the stack * if necessary. * @param new_buffer The new state. - * + * */ void yypush_buffer_state (YY_BUFFER_STATE new_buffer ) { @@ -2009,7 +2021,7 @@ void yypush_buffer_state (YY_BUFFER_STATE new_buffer ) /** Removes and deletes the top of the stack, if present. * The next element becomes the new top. - * + * */ void yypop_buffer_state (void) { @@ -2033,7 +2045,7 @@ void yypop_buffer_state (void) static void yyensure_buffer_stack (void) { yy_size_t num_to_alloc; - + if (!(yy_buffer_stack)) { /* First allocation is just for 2 elements, since we don't know if this @@ -2046,9 +2058,9 @@ static void yyensure_buffer_stack (void) ); if ( ! (yy_buffer_stack) ) YY_FATAL_ERROR( "out of dynamic memory in yyensure_buffer_stack()" ); - + memset((yy_buffer_stack), 0, num_to_alloc * sizeof(struct yy_buffer_state*)); - + (yy_buffer_stack_max) = num_to_alloc; (yy_buffer_stack_top) = 0; return; @@ -2076,13 +2088,13 @@ static void yyensure_buffer_stack (void) /** Setup the input buffer state to scan directly from a user-specified character buffer. * @param base the character buffer * @param size the size in bytes of the character buffer - * - * @return the newly allocated buffer state object. + * + * @return the newly allocated buffer state object. */ YY_BUFFER_STATE yy_scan_buffer (char * base, yy_size_t size ) { YY_BUFFER_STATE b; - + if ( size < 2 || base[size-2] != YY_END_OF_BUFFER_CHAR || base[size-1] != YY_END_OF_BUFFER_CHAR ) @@ -2111,14 +2123,14 @@ YY_BUFFER_STATE yy_scan_buffer (char * base, yy_size_t size ) /** Setup the input buffer state to scan a string. The next call to yylex() will * scan from a @e copy of @a str. * @param yystr a NUL-terminated string to scan - * + * * @return the newly allocated buffer state object. * @note If you want to scan bytes that may contain NUL values, then use * yy_scan_bytes() instead. */ YY_BUFFER_STATE yy_scan_string (yyconst char * yystr ) { - + return yy_scan_bytes(yystr,strlen(yystr) ); } @@ -2126,7 +2138,7 @@ YY_BUFFER_STATE yy_scan_string (yyconst char * yystr ) * scan from a @e copy of @a bytes. * @param bytes the byte buffer to scan * @param len the number of bytes in the buffer pointed to by @a bytes. - * + * * @return the newly allocated buffer state object. */ YY_BUFFER_STATE yy_scan_bytes (yyconst char * yybytes, yy_size_t _yybytes_len ) @@ -2134,7 +2146,7 @@ YY_BUFFER_STATE yy_scan_bytes (yyconst char * yybytes, yy_size_t _yybytes_len YY_BUFFER_STATE b; char *buf; yy_size_t n, i; - + /* Get memory for full buffer, including space for trailing EOB's. */ n = _yybytes_len + 2; buf = (char *) yyalloc(n ); @@ -2188,16 +2200,16 @@ static void yy_fatal_error (yyconst char* msg ) /* Accessor methods (get/set functions) to struct members. */ /** Get the current line number. - * + * */ int yyget_lineno (void) { - + return yylineno; } /** Get the input stream. - * + * */ FILE *yyget_in (void) { @@ -2205,7 +2217,7 @@ FILE *yyget_in (void) } /** Get the output stream. - * + * */ FILE *yyget_out (void) { @@ -2213,7 +2225,7 @@ FILE *yyget_out (void) } /** Get the length of the current token. - * + * */ yy_size_t yyget_leng (void) { @@ -2221,7 +2233,7 @@ yy_size_t yyget_leng (void) } /** Get the current token. - * + * */ char *yyget_text (void) @@ -2231,18 +2243,18 @@ char *yyget_text (void) /** Set the current line number. * @param line_number - * + * */ void yyset_lineno (int line_number ) { - + yylineno = line_number; } /** Set the input stream. This does not discard the current * input buffer. * @param in_str A readable stream. - * + * * @see yy_switch_to_buffer */ void yyset_in (FILE * in_str ) @@ -2296,7 +2308,7 @@ static int yy_init_globals (void) /* yylex_destroy is for both reentrant and non-reentrant scanners. */ int yylex_destroy (void) { - + /* Pop the buffer stack, destroying each element. */ while(YY_CURRENT_BUFFER){ yy_delete_buffer(YY_CURRENT_BUFFER ); @@ -2363,7 +2375,7 @@ void yyfree (void * ptr ) #define YYTABLES_NAME "yytables" -#line 222 "engines/director/lingo/lingo-lex.l" +#line 224 "engines/director/lingo/lingo-lex.l" diff --git a/engines/director/lingo/lingo-lex.l b/engines/director/lingo/lingo-lex.l index c2a5b19fb9..39aef99d61 100644 --- a/engines/director/lingo/lingo-lex.l +++ b/engines/director/lingo/lingo-lex.l @@ -92,12 +92,14 @@ whitespace [\t ] (?i:into) { count(); return tINTO; } (?i:loop) { count(); return tLOOP; } (?i:macro) { count(); return tMACRO; } +(?i:me) { count(); return tME; } (?i:method) { count(); return tMETHOD; } (?i:mod) { count(); return tMOD; } (?i:movie) { count(); return tMOVIE; } (?i:next) { count(); return tNEXT; } (?i:not) { count(); return tNOT; } (?i:of) { count(); return tOF; } +(?i:on) { count(); return tON; } (?i:open) { count(); return tOPEN; } (?i:or) { count(); return tOR; } (?i:play) { count(); return tPLAY; } |