aboutsummaryrefslogtreecommitdiff
path: root/engines
diff options
context:
space:
mode:
authorEugene Sandulenko2016-08-20 12:59:59 +0200
committerEugene Sandulenko2016-08-20 12:59:59 +0200
commitfdd4e8369a1dfd8726b533f74b80bb414db0e612 (patch)
treee0b35c30816d789f8028c555b67113e57b3965bf /engines
parentdcbc7e3b4de8525c4638c151eb3a7a662e3b15e1 (diff)
downloadscummvm-rg350-fdd4e8369a1dfd8726b533f74b80bb414db0e612.tar.gz
scummvm-rg350-fdd4e8369a1dfd8726b533f74b80bb414db0e612.tar.bz2
scummvm-rg350-fdd4e8369a1dfd8726b533f74b80bb414db0e612.zip
DIRECTOR: Lingo: Defined 'mod' operator and specified operator precedence
Diffstat (limited to 'engines')
-rw-r--r--engines/director/lingo/lingo-code.cpp16
-rw-r--r--engines/director/lingo/lingo-gr.cpp1090
-rw-r--r--engines/director/lingo/lingo-gr.h28
-rw-r--r--engines/director/lingo/lingo-gr.y7
-rw-r--r--engines/director/lingo/lingo-lex.cpp429
-rw-r--r--engines/director/lingo/lingo-lex.l1
-rw-r--r--engines/director/lingo/lingo.h1
7 files changed, 809 insertions, 763 deletions
diff --git a/engines/director/lingo/lingo-code.cpp b/engines/director/lingo/lingo-code.cpp
index c97d669ff8..1e78b2db13 100644
--- a/engines/director/lingo/lingo-code.cpp
+++ b/engines/director/lingo/lingo-code.cpp
@@ -73,6 +73,7 @@ static struct FuncDescr {
{ Lingo::c_sub, "c_sub", "" },
{ Lingo::c_mul, "c_mul", "" },
{ Lingo::c_div, "c_div", "" },
+ { Lingo::c_mod, "c_mod", "" },
{ Lingo::c_negate, "c_negate", "" },
{ Lingo::c_ampersand, "c_ampersand", "" },
{ Lingo::c_concat, "c_concat", "" },
@@ -414,6 +415,21 @@ void Lingo::c_div() {
g_lingo->push(d1);
}
+void Lingo::c_mod() {
+ Datum d2 = g_lingo->pop();
+ d2.toInt();
+
+ if (d2.u.i == 0)
+ error("division by zero");
+
+ Datum d1 = g_lingo->pop();
+ d1.toInt();
+
+ d1.u.i %= d2.u.i;
+
+ g_lingo->push(d1);
+}
+
void Lingo::c_negate() {
Datum d = g_lingo->pop();
diff --git a/engines/director/lingo/lingo-gr.cpp b/engines/director/lingo/lingo-gr.cpp
index 3837029a5f..c7cb87c2cb 100644
--- a/engines/director/lingo/lingo-gr.cpp
+++ b/engines/director/lingo/lingo-gr.cpp
@@ -128,12 +128,13 @@
tAND = 317,
tOR = 318,
tNOT = 319,
- tCONCAT = 320,
- tCONTAINS = 321,
- tSTARTS = 322,
- tSPRITE = 323,
- tINTERSECTS = 324,
- tWITHIN = 325
+ tMOD = 320,
+ tCONCAT = 321,
+ tCONTAINS = 322,
+ tSTARTS = 323,
+ tSPRITE = 324,
+ tINTERSECTS = 325,
+ tWITHIN = 326
};
#endif
/* Tokens. */
@@ -199,12 +200,13 @@
#define tAND 317
#define tOR 318
#define tNOT 319
-#define tCONCAT 320
-#define tCONTAINS 321
-#define tSTARTS 322
-#define tSPRITE 323
-#define tINTERSECTS 324
-#define tWITHIN 325
+#define tMOD 320
+#define tCONCAT 321
+#define tCONTAINS 322
+#define tSTARTS 323
+#define tSPRITE 324
+#define tINTERSECTS 325
+#define tWITHIN 326
@@ -262,7 +264,7 @@ typedef union YYSTYPE
Common::Array<double> *arr;
}
/* Line 193 of yacc.c. */
-#line 266 "engines/director/lingo/lingo-gr.cpp"
+#line 268 "engines/director/lingo/lingo-gr.cpp"
YYSTYPE;
# define yystype YYSTYPE /* obsolescent; will be withdrawn */
# define YYSTYPE_IS_DECLARED 1
@@ -275,7 +277,7 @@ typedef union YYSTYPE
/* Line 216 of yacc.c. */
-#line 279 "engines/director/lingo/lingo-gr.cpp"
+#line 281 "engines/director/lingo/lingo-gr.cpp"
#ifdef short
# undef short
@@ -490,20 +492,20 @@ union yyalloc
/* YYFINAL -- State number of the termination state. */
#define YYFINAL 92
/* YYLAST -- Last index in YYTABLE. */
-#define YYLAST 978
+#define YYLAST 995
/* YYNTOKENS -- Number of terminals. */
-#define YYNTOKENS 84
+#define YYNTOKENS 85
/* YYNNTS -- Number of nonterminals. */
#define YYNNTS 37
/* YYNRULES -- Number of rules. */
-#define YYNRULES 129
+#define YYNRULES 130
/* YYNRULES -- Number of states. */
-#define YYNSTATES 267
+#define YYNSTATES 269
/* YYTRANSLATE(YYLEX) -- Bison symbol number corresponding to YYLEX. */
#define YYUNDEFTOK 2
-#define YYMAXUTOK 325
+#define YYMAXUTOK 326
#define YYTRANSLATE(YYX) \
((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK)
@@ -512,12 +514,12 @@ union yyalloc
static const yytype_uint8 yytranslate[] =
{
0, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 77, 2, 2, 2, 2, 2, 2, 2, 2, 2,
+ 79, 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, 76, 82, 2,
- 78, 79, 74, 72, 83, 73, 2, 75, 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, 2, 2, 2,
- 81, 71, 80, 2, 2, 2, 2, 2, 2, 2,
+ 83, 72, 82, 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,
@@ -543,7 +545,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
+ 65, 66, 67, 68, 69, 70, 71
};
#if YYDEBUG
@@ -558,83 +560,86 @@ static const yytype_uint16 yyprhs[] =
192, 194, 200, 202, 206, 210, 213, 217, 219, 221,
222, 223, 224, 227, 230, 234, 236, 238, 240, 242,
247, 249, 251, 254, 256, 260, 264, 268, 272, 276,
- 280, 284, 288, 292, 296, 300, 303, 307, 311, 315,
- 319, 322, 325, 329, 334, 339, 342, 344, 346, 349,
- 351, 354, 357, 360, 363, 365, 368, 373, 376, 378,
- 382, 384, 388, 391, 394, 397, 400, 404, 407, 410,
- 412, 416, 419, 422, 425, 429, 432, 433, 442, 445,
- 446, 455, 456, 458, 462, 467, 468, 472, 473, 475
+ 280, 284, 288, 292, 296, 300, 304, 307, 311, 315,
+ 319, 323, 326, 329, 333, 338, 343, 346, 348, 350,
+ 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
};
/* YYRHS -- A `-1'-separated list of the rules' RHS. */
static const yytype_int8 yyrhs[] =
{
- 85, 0, -1, 85, 86, 87, -1, 87, -1, 1,
- 86, -1, 77, -1, -1, 114, -1, 107, -1, 119,
- -1, 88, -1, 90, -1, 40, 106, 33, 21, -1,
- 42, 21, 71, 106, -1, 42, 13, 71, 106, -1,
- 42, 14, 106, 71, 106, -1, 42, 21, 44, 106,
- -1, 42, 13, 44, 106, -1, 42, 14, 106, 44,
- 106, -1, 106, -1, 107, -1, 89, -1, 91, -1,
- 98, 78, 97, 79, 104, 103, 27, 41, -1, 99,
- 71, 106, 103, 44, 106, 103, 104, 103, 27, 41,
- -1, 99, 71, 106, 103, 24, 44, 106, 103, 104,
- 103, 27, 41, -1, 105, 106, 103, -1, 100, 97,
- 43, 86, 104, 103, 27, 32, -1, 100, 97, 43,
- 86, 104, 103, 48, 104, 103, 27, 32, -1, 100,
- 97, 43, 86, 104, 103, 102, 93, 103, 27, 32,
- -1, 100, 97, 43, 102, 89, 103, -1, 100, 97,
- 43, 102, 89, 103, 48, 102, 89, 103, -1, 100,
- 97, 43, 102, 89, 103, 94, 103, 92, 103, -1,
- -1, 48, 102, 89, -1, 93, 96, -1, 96, -1,
- 94, 95, -1, 95, -1, 101, 97, 43, 102, 90,
- 103, -1, 94, -1, 101, 97, 43, 104, 103, -1,
- 106, -1, 106, 71, 106, -1, 78, 97, 79, -1,
+ 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,
41, 47, -1, 41, 46, 21, -1, 32, -1, 26,
- -1, -1, -1, -1, 104, 86, -1, 104, 90, -1,
+ -1, -1, -1, -1, 105, 87, -1, 105, 91, -1,
45, 21, 43, -1, 12, -1, 15, -1, 22, -1,
- 17, -1, 21, 78, 120, 79, -1, 21, -1, 13,
- -1, 14, 106, -1, 88, -1, 106, 72, 106, -1,
- 106, 73, 106, -1, 106, 74, 106, -1, 106, 75,
- 106, -1, 106, 80, 106, -1, 106, 81, 106, -1,
- 106, 61, 106, -1, 106, 56, 106, -1, 106, 57,
- 106, -1, 106, 62, 106, -1, 106, 63, 106, -1,
- 64, 106, -1, 106, 82, 106, -1, 106, 65, 106,
- -1, 106, 66, 106, -1, 106, 67, 106, -1, 72,
- 106, -1, 73, 106, -1, 78, 106, 79, -1, 68,
- 106, 69, 106, -1, 68, 106, 70, 106, -1, 40,
- 106, -1, 110, -1, 113, -1, 28, 41, -1, 28,
- -1, 30, 108, -1, 55, 109, -1, 19, 106, -1,
- 18, 106, -1, 18, -1, 20, 120, -1, 51, 106,
- 46, 106, -1, 51, 106, -1, 21, -1, 108, 83,
- 21, -1, 21, -1, 109, 83, 21, -1, 31, 34,
- -1, 31, 37, -1, 31, 39, -1, 31, 111, -1,
- 31, 111, 112, -1, 31, 112, -1, 29, 106, -1,
- 106, -1, 38, 36, 106, -1, 36, 106, -1, 52,
- 53, -1, 52, 111, -1, 52, 111, 112, -1, 52,
- 112, -1, -1, 35, 21, 115, 102, 117, 86, 118,
- 104, -1, 49, 21, -1, -1, 50, 21, 116, 102,
- 117, 86, 118, 104, -1, -1, 21, -1, 117, 83,
- 21, -1, 117, 86, 83, 21, -1, -1, 21, 102,
- 120, -1, -1, 106, -1, 120, 83, 106, -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,
+ 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
};
/* YYRLINE[YYN] -- source line where rule number YYN was defined. */
static const yytype_uint16 yyrline[] =
{
- 0, 103, 103, 104, 105, 108, 113, 114, 115, 116,
- 117, 118, 121, 127, 133, 141, 149, 155, 163, 172,
- 173, 175, 176, 181, 192, 208, 220, 228, 235, 244,
- 253, 263, 273, 284, 285, 288, 289, 292, 293, 296,
- 304, 305, 313, 314, 315, 317, 319, 325, 331, 338,
- 340, 342, 343, 344, 347, 353, 354, 357, 360, 364,
- 367, 371, 378, 384, 385, 386, 387, 388, 389, 390,
- 391, 392, 393, 394, 395, 396, 397, 398, 399, 400,
- 401, 402, 403, 404, 405, 408, 409, 410, 411, 412,
- 414, 415, 416, 419, 422, 425, 426, 427, 430, 431,
- 434, 435, 446, 447, 448, 449, 452, 455, 460, 461,
- 464, 465, 468, 469, 472, 475, 505, 505, 511, 514,
- 514, 519, 520, 521, 522, 524, 528, 536, 537, 538
+ 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, 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, 523, 524, 525, 527, 531, 539, 540,
+ 541
};
#endif
@@ -652,10 +657,10 @@ static const char *const yytname[] =
"tPUT", "tREPEAT", "tSET", "tTHEN", "tTO", "tWHEN", "tWITH", "tWHILE",
"tNLELSE", "tFACTORY", "tMETHOD", "tOPEN", "tPLAY", "tDONE",
"tPLAYACCEL", "tINSTANCE", "tGE", "tLE", "tGT", "tLT", "tEQ", "tNEQ",
- "tAND", "tOR", "tNOT", "tCONCAT", "tCONTAINS", "tSTARTS", "tSPRITE",
- "tINTERSECTS", "tWITHIN", "'='", "'+'", "'-'", "'*'", "'/'", "'%'",
- "'\\n'", "'('", "')'", "'>'", "'<'", "'&'", "','", "$accept", "program",
- "nl", "programline", "asgn", "stmtoneliner", "stmt", "ifstmt",
+ "tAND", "tOR", "tNOT", "tMOD", "tCONCAT", "tCONTAINS", "tSTARTS",
+ "tSPRITE", "tINTERSECTS", "tWITHIN", "'='", "'&'", "'+'", "'-'", "'*'",
+ "'/'", "'%'", "'\\n'", "'('", "')'", "'>'", "'<'", "','", "$accept",
+ "program", "nl", "programline", "asgn", "stmtoneliner", "stmt", "ifstmt",
"elsestmtoneliner", "elseifstmt", "elseifstmtoneliner",
"elseifstmtoneliner1", "elseifstmt1", "cond", "repeatwhile",
"repeatwith", "if", "elseif", "begin", "end", "stmtlist", "when", "expr",
@@ -677,27 +682,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, 61, 43, 45, 42, 47, 37, 10, 40, 41,
- 62, 60, 38, 44
+ 325, 326, 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, 84, 85, 85, 85, 86, 87, 87, 87, 87,
- 87, 87, 88, 88, 88, 88, 88, 88, 88, 89,
- 89, 90, 90, 90, 90, 90, 90, 91, 91, 91,
- 91, 91, 91, 92, 92, 93, 93, 94, 94, 95,
- 96, 96, 97, 97, 97, 98, 99, 100, 101, 102,
- 103, 104, 104, 104, 105, 106, 106, 106, 106, 106,
- 106, 106, 106, 106, 106, 106, 106, 106, 106, 106,
- 106, 106, 106, 106, 106, 106, 106, 106, 106, 106,
- 106, 106, 106, 106, 106, 107, 107, 107, 107, 107,
- 107, 107, 107, 107, 107, 107, 107, 107, 108, 108,
- 109, 109, 110, 110, 110, 110, 110, 110, 111, 111,
- 112, 112, 113, 113, 113, 113, 115, 114, 114, 116,
- 114, 117, 117, 117, 117, 118, 119, 120, 120, 120
+ 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
};
/* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN. */
@@ -710,12 +716,13 @@ static const yytype_uint8 yyr2[] =
1, 5, 1, 3, 3, 2, 3, 1, 1, 0,
0, 0, 2, 2, 3, 1, 1, 1, 1, 4,
1, 1, 2, 1, 3, 3, 3, 3, 3, 3,
- 3, 3, 3, 3, 3, 2, 3, 3, 3, 3,
- 2, 2, 3, 4, 4, 2, 1, 1, 2, 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
+ 3, 3, 3, 3, 3, 3, 2, 3, 3, 3,
+ 3, 2, 2, 3, 4, 4, 2, 1, 1, 2,
+ 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
};
/* YYDEFACT[STATE-NAME] -- Default rule to reduce with in state
@@ -723,85 +730,85 @@ static const yytype_uint8 yyr2[] =
means the default is an error. */
static const yytype_uint8 yydefact[] =
{
- 0, 0, 55, 61, 0, 56, 58, 94, 0, 127,
- 49, 57, 89, 0, 0, 47, 0, 0, 0, 0,
+ 0, 0, 55, 61, 0, 56, 58, 95, 0, 128,
+ 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, 86, 87, 7, 9, 5, 4, 60,
- 0, 63, 62, 93, 92, 128, 95, 127, 127, 88,
- 98, 90, 0, 102, 0, 103, 0, 104, 109, 105,
- 107, 116, 85, 0, 45, 0, 0, 0, 0, 118,
- 119, 97, 112, 113, 115, 100, 91, 75, 0, 80,
- 81, 0, 1, 6, 0, 0, 0, 0, 42, 50,
+ 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, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 126, 0,
- 108, 111, 0, 106, 49, 0, 46, 0, 0, 0,
- 0, 0, 54, 49, 0, 114, 0, 0, 0, 82,
- 2, 0, 50, 0, 0, 49, 0, 26, 71, 72,
- 70, 73, 74, 77, 78, 79, 64, 65, 66, 67,
- 68, 69, 76, 129, 59, 99, 110, 121, 12, 17,
- 14, 0, 0, 16, 13, 121, 96, 101, 83, 84,
- 51, 0, 44, 51, 0, 43, 122, 0, 18, 15,
- 0, 50, 0, 0, 50, 50, 20, 0, 125, 125,
- 52, 53, 0, 0, 50, 49, 30, 123, 0, 51,
- 51, 0, 50, 51, 0, 51, 0, 48, 49, 50,
- 38, 0, 124, 117, 120, 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, 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
};
/* YYDEFGOTO[NTERM-NUM]. */
static const yytype_int16 yydefgoto[] =
{
- -1, 31, 200, 32, 51, 34, 201, 36, 246, 230,
- 231, 220, 232, 97, 37, 38, 39, 221, 256, 147,
- 191, 40, 41, 196, 61, 86, 43, 69, 70, 44,
- 45, 124, 133, 187, 209, 46, 56
+ -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
};
/* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing
STATE-NUM. */
-#define YYPACT_NINF -203
+#define YYPACT_NINF -206
static const yytype_int16 yypact[] =
{
- 275, -52, -203, -203, 653, -203, -203, 653, 653, 653,
- 869, -203, -5, 29, 578, -203, 36, 653, -23, 6,
- 38, 39, 41, 653, 619, 42, 653, 653, 653, 653,
- 653, 8, -203, 9, -203, -203, -203, -34, 4, 664,
- 653, 847, -203, -203, -203, -203, -203, -203, -203, -12,
- 653, -203, 847, 847, 847, 847, -18, 653, 653, -203,
- -203, -4, 653, -203, 653, -203, 45, -203, 847, 11,
- -203, -203, 678, 56, -203, -37, 653, -32, 35, -203,
- -203, 727, -203, 11, -203, -203, -1, 163, 749, 163,
- 163, 798, -203, 342, 664, 653, 664, 46, 825, 847,
- 653, 653, 653, 653, 653, 653, 653, 653, 653, 653,
- 653, 653, 653, 653, 653, 678, 653, -48, -18, 66,
- 847, 847, 653, -203, -203, 67, -203, 653, 653, 705,
- 653, 653, -203, -203, 653, -203, 69, 653, 653, -203,
- -203, 12, 847, 13, 771, -52, 653, -203, 847, 847,
- 847, 847, 847, 847, 847, 847, 896, 896, 163, 163,
- 847, 847, 847, 847, -203, -203, 847, 74, -203, 847,
- 847, 653, 653, 847, 847, 74, 847, -203, 847, 847,
- -203, 2, -203, -203, 533, 847, -203, -55, 847, 847,
- -55, 404, 53, 653, 404, -203, -203, 78, 17, 17,
- -203, -203, 76, 653, 847, -6, -8, -203, 83, -203,
- -203, 64, 847, -203, 75, -203, 84, -203, -203, 84,
- -203, 664, -203, 404, 404, -203, -203, 404, -203, 404,
- 84, 84, -203, 664, 533, -203, 61, 68, 404, 85,
- 86, -203, 87, 73, -203, -203, -203, -203, 90, 77,
- 89, 91, -13, -203, 533, -203, 471, 81, -203, -203,
- -203, 404, -203, -203, -203, -203, -203
+ 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
};
/* YYPGOTO[NTERM-NUM]. */
static const yytype_int16 yypgoto[] =
{
- -203, -203, 14, 26, 3, -178, 0, -203, -203, -203,
- -81, -202, -104, -92, -203, -203, -203, -200, -9, 23,
- -172, -203, 44, 5, -203, -203, -203, 103, -14, -203,
- -203, -203, -203, -47, -69, -203, -25
+ -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
};
/* YYTABLE[YYPACT[STATE-NUM]]. What to do in state STATE-NUM. If
@@ -811,206 +818,210 @@ static const yytype_int16 yypgoto[] =
#define YYTABLE_NINF -61
static const yytype_int16 yytable[] =
{
- 35, 58, 141, 33, 143, 42, 195, 127, 92, -10,
- 84, 194, 130, -51, -51, 48, 233, 235, 217, 75,
- 76, 214, 47, 73, 74, 47, 192, 77, 197, 235,
- 233, 164, 117, 118, 128, 116, 59, 223, 224, 131,
- 218, 227, 215, 229, 94, 93, 193, 64, 52, 66,
- 60, 53, 54, 55, 238, 123, 244, 71, 68, 78,
- 79, 72, 80, 85, -51, 116, 57, 81, 68, 135,
- 87, 88, 89, 90, 91, 95, 262, 126, 132, 119,
- 261, 122, 136, 98, 99, 47, -10, 165, 168, 145,
- 177, 180, 182, 35, 115, 186, 33, 203, 42, 207,
- 208, 55, 55, 211, 222, 225, 120, 228, 121, 245,
- 217, 247, 249, 250, 251, 167, 252, 257, 258, 140,
- 129, 259, 264, 260, 175, 219, 241, 83, 190, 237,
- 210, 0, 0, 0, 0, 0, 184, 0, 98, 142,
- 144, 243, 0, 0, 148, 149, 150, 151, 152, 153,
- 154, 155, 156, 157, 158, 159, 160, 161, 162, 183,
- 163, 0, 0, 0, 0, 181, 166, 0, 0, 0,
- 0, 169, 170, 0, 173, 174, 0, 0, 176, 0,
- 0, 178, 179, 0, 0, 0, 0, 0, 0, 0,
- 185, 0, 0, 0, 0, 0, 216, 0, 0, 0,
- 0, 198, 0, 0, 199, 0, 0, 0, 0, 234,
- 0, 0, 0, 0, 202, 188, 189, 205, 206, 100,
- 101, 0, 0, 0, 102, 103, 104, 213, 105, 106,
- 107, 0, 0, 0, 0, 226, 254, 204, 0, 0,
- 0, 0, 236, 112, 113, 114, 0, 212, 0, 0,
- 239, 0, 240, 242, 0, 0, 263, 0, 0, 0,
- 0, 248, 0, 0, 0, 98, 0, 253, 0, 255,
- 0, 0, 0, 0, 0, -6, 1, 98, 0, 0,
- 0, 0, 0, 0, 265, 0, 266, 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, 0, 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, 27, 0, 0, 0, 28, 29, 0,
+ 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,
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,
0, 0, 0, 0, 0, 0, 26, 0, 0, 0,
- 27, 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, 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, 27, 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, 27,
+ 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,
+ 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, 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,
- 2, 3, 4, 5, 0, 6, 0, 26, 0, 49,
- 11, 27, 0, 0, 0, 28, 29, 62, 0, 0,
- 0, 30, 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, 27, 0, 62, 0,
- 28, 29, 0, 0, 0, 64, 30, 66, 0, 50,
- 0, 19, 0, 0, 0, 2, 3, 4, 5, 0,
- 6, 0, 82, 0, 49, 11, 2, 3, 4, 5,
- 0, 6, 0, 26, 0, 49, 11, 27, 0, 0,
- 0, 28, 29, 50, 0, 19, 0, 30, 0, 0,
- 0, 0, 0, 0, 50, 0, 19, 0, 0, 0,
- 0, 125, 0, 0, 0, 0, 0, 26, 0, 0,
- 0, 27, 0, 0, 0, 28, 29, 0, 26, 0,
- 0, 30, 27, 0, 100, 101, 28, 29, 0, 102,
- 103, 104, 96, 105, 106, 107, 0, 0, 0, 171,
- 108, 109, 110, 111, 0, 0, 0, 0, 112, 113,
- 114, 100, 101, 0, 0, 0, 102, 103, 104, 0,
- 105, 106, 107, 134, 0, 0, 172, 108, 109, 110,
- 111, 0, 0, 100, 101, 112, 113, 114, 102, 103,
- 104, 0, 105, 106, 107, 0, 0, 0, 0, 108,
- 109, 110, 111, 0, 0, 100, 101, 112, 113, 114,
- 102, 103, 104, 0, 105, 106, 107, 0, 137, 138,
- 0, 108, 109, 110, 111, 0, 0, 100, 101, 112,
- 113, 114, 102, 103, 104, 0, 105, 106, 107, 0,
- 0, 0, 146, 108, 109, 110, 111, 0, 0, 0,
- 139, 112, 113, 114, 100, 101, 0, 0, 0, 102,
- 103, 104, 0, 105, 106, 107, 0, 0, 0, 0,
- 108, 109, 110, 111, 0, 0, 0, 139, 112, 113,
- 114, 100, 101, 0, 0, 0, 102, 103, 104, 0,
- 105, 106, 107, 0, 0, 0, 146, 108, 109, 110,
- 111, 0, 0, 100, 101, 112, 113, 114, 102, 103,
- 104, 0, 105, 106, 107, 0, 0, 0, 0, 108,
- 109, 110, 111, 0, 0, -60, -60, 112, 113, 114,
- -60, -60, -60, 0, -60, -60, -60, 0, 0, 0,
- 0, 0, 0, -60, -60, 0, 0, 57, 0, -60,
- -60, -60, 100, 101, 0, 0, 0, 102, 103, 104,
- 0, 105, 106, 107, 0, 0, 0, 0, 0, 0,
- 110, 111, 0, 0, 0, 0, 112, 113, 114
+ 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
};
static const yytype_int16 yycheck[] =
{
- 0, 10, 94, 0, 96, 0, 184, 44, 0, 0,
- 24, 183, 44, 26, 27, 1, 216, 219, 26, 13,
- 14, 27, 77, 46, 47, 77, 24, 21, 83, 231,
- 230, 79, 57, 58, 71, 83, 41, 209, 210, 71,
- 48, 213, 48, 215, 78, 31, 44, 36, 4, 38,
- 21, 7, 8, 9, 226, 69, 234, 21, 14, 21,
- 21, 17, 21, 21, 77, 83, 78, 23, 24, 83,
- 26, 27, 28, 29, 30, 71, 254, 21, 43, 83,
- 252, 36, 83, 39, 40, 77, 77, 21, 21, 43,
- 21, 79, 79, 93, 50, 21, 93, 44, 93, 21,
- 83, 57, 58, 27, 21, 41, 62, 32, 64, 48,
- 26, 43, 27, 27, 27, 124, 43, 27, 41, 93,
- 76, 32, 41, 32, 133, 206, 230, 24, 175, 221,
- 199, -1, -1, -1, -1, -1, 145, -1, 94, 95,
- 96, 233, -1, -1, 100, 101, 102, 103, 104, 105,
- 106, 107, 108, 109, 110, 111, 112, 113, 114, 145,
- 116, -1, -1, -1, -1, 142, 122, -1, -1, -1,
- -1, 127, 128, -1, 130, 131, -1, -1, 134, -1,
- -1, 137, 138, -1, -1, -1, -1, -1, -1, -1,
- 146, -1, -1, -1, -1, -1, 205, -1, -1, -1,
- -1, 187, -1, -1, 190, -1, -1, -1, -1, 218,
- -1, -1, -1, -1, 191, 171, 172, 194, 195, 56,
- 57, -1, -1, -1, 61, 62, 63, 204, 65, 66,
- 67, -1, -1, -1, -1, 212, 245, 193, -1, -1,
- -1, -1, 219, 80, 81, 82, -1, 203, -1, -1,
- 227, -1, 229, 230, -1, -1, 256, -1, -1, -1,
- -1, 238, -1, -1, -1, 221, -1, 244, -1, 246,
- -1, -1, -1, -1, -1, 0, 1, 233, -1, -1,
- -1, -1, -1, -1, 261, -1, 263, 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, -1, -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, 68, -1, -1, -1, 72, 73, -1,
- -1, -1, 77, 78, 12, 13, 14, 15, -1, 17,
+ 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,
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,
-1, -1, -1, -1, -1, -1, 64, -1, -1, -1,
- 68, -1, -1, -1, 72, 73, 12, 13, 14, 15,
- 78, 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, 68, -1, -1, -1, 72, 73, -1, -1,
- -1, 77, 78, 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, 68,
- -1, -1, -1, 72, 73, 12, 13, 14, 15, 78,
- 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,
- 12, 13, 14, 15, -1, 17, -1, 64, -1, 21,
- 22, 68, -1, -1, -1, 72, 73, 29, -1, -1,
- -1, 78, 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, 68, -1, 29, -1,
- 72, 73, -1, -1, -1, 36, 78, 38, -1, 40,
- -1, 42, -1, -1, -1, 12, 13, 14, 15, -1,
- 17, -1, 53, -1, 21, 22, 12, 13, 14, 15,
- -1, 17, -1, 64, -1, 21, 22, 68, -1, -1,
- -1, 72, 73, 40, -1, 42, -1, 78, -1, -1,
- -1, -1, -1, -1, 40, -1, 42, -1, -1, -1,
- -1, 33, -1, -1, -1, -1, -1, 64, -1, -1,
- -1, 68, -1, -1, -1, 72, 73, -1, 64, -1,
- -1, 78, 68, -1, 56, 57, 72, 73, -1, 61,
- 62, 63, 78, 65, 66, 67, -1, -1, -1, 44,
- 72, 73, 74, 75, -1, -1, -1, -1, 80, 81,
- 82, 56, 57, -1, -1, -1, 61, 62, 63, -1,
- 65, 66, 67, 46, -1, -1, 71, 72, 73, 74,
- 75, -1, -1, 56, 57, 80, 81, 82, 61, 62,
- 63, -1, 65, 66, 67, -1, -1, -1, -1, 72,
- 73, 74, 75, -1, -1, 56, 57, 80, 81, 82,
- 61, 62, 63, -1, 65, 66, 67, -1, 69, 70,
- -1, 72, 73, 74, 75, -1, -1, 56, 57, 80,
- 81, 82, 61, 62, 63, -1, 65, 66, 67, -1,
- -1, -1, 71, 72, 73, 74, 75, -1, -1, -1,
- 79, 80, 81, 82, 56, 57, -1, -1, -1, 61,
- 62, 63, -1, 65, 66, 67, -1, -1, -1, -1,
- 72, 73, 74, 75, -1, -1, -1, 79, 80, 81,
- 82, 56, 57, -1, -1, -1, 61, 62, 63, -1,
- 65, 66, 67, -1, -1, -1, 71, 72, 73, 74,
- 75, -1, -1, 56, 57, 80, 81, 82, 61, 62,
- 63, -1, 65, 66, 67, -1, -1, -1, -1, 72,
- 73, 74, 75, -1, -1, 56, 57, 80, 81, 82,
- 61, 62, 63, -1, 65, 66, 67, -1, -1, -1,
- -1, -1, -1, 74, 75, -1, -1, 78, -1, 80,
- 81, 82, 56, 57, -1, -1, -1, 61, 62, 63,
- -1, 65, 66, 67, -1, -1, -1, -1, -1, -1,
- 74, 75, -1, -1, -1, -1, 80, 81, 82
+ -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,
+ -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
};
/* YYSTOS[STATE-NUM] -- The (internal number of the) accessing
@@ -1019,31 +1030,31 @@ 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, 68, 72, 73,
- 78, 85, 87, 88, 89, 90, 91, 98, 99, 100,
- 105, 106, 107, 110, 113, 114, 119, 77, 86, 21,
- 40, 88, 106, 106, 106, 106, 120, 78, 102, 41,
- 21, 108, 29, 34, 36, 37, 38, 39, 106, 111,
- 112, 21, 106, 46, 47, 13, 14, 21, 21, 21,
- 21, 106, 53, 111, 112, 21, 109, 106, 106, 106,
- 106, 106, 0, 86, 78, 71, 78, 97, 106, 106,
- 56, 57, 61, 62, 63, 65, 66, 67, 72, 73,
- 74, 75, 80, 81, 82, 106, 83, 120, 120, 83,
- 106, 106, 36, 112, 115, 33, 21, 44, 71, 106,
- 44, 71, 43, 116, 46, 112, 83, 69, 70, 79,
- 87, 97, 106, 97, 106, 43, 71, 103, 106, 106,
- 106, 106, 106, 106, 106, 106, 106, 106, 106, 106,
- 106, 106, 106, 106, 79, 21, 106, 102, 21, 106,
- 106, 44, 71, 106, 106, 102, 106, 21, 106, 106,
- 79, 103, 79, 86, 102, 106, 21, 117, 106, 106,
- 117, 104, 24, 44, 104, 89, 107, 83, 86, 86,
- 86, 90, 103, 44, 106, 103, 103, 21, 83, 118,
- 118, 27, 106, 103, 27, 48, 102, 26, 48, 94,
- 95, 101, 21, 104, 104, 41, 103, 104, 32, 104,
- 93, 94, 96, 101, 102, 95, 103, 97, 104, 103,
- 103, 96, 103, 97, 89, 48, 92, 43, 103, 27,
- 27, 27, 43, 103, 102, 103, 102, 27, 41, 32,
- 32, 104, 89, 90, 41, 103, 103
+ 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
};
#define yyerrok (yyerrstatus = 0)
@@ -1858,12 +1869,12 @@ yyreduce:
switch (yyn)
{
case 4:
-#line 105 "engines/director/lingo/lingo-gr.y"
+#line 107 "engines/director/lingo/lingo-gr.y"
{ yyerrok; ;}
break;
case 5:
-#line 108 "engines/director/lingo/lingo-gr.y"
+#line 110 "engines/director/lingo/lingo-gr.y"
{
g_lingo->_linenumber++;
g_lingo->_colnumber = 1;
@@ -1871,12 +1882,12 @@ yyreduce:
break;
case 10:
-#line 117 "engines/director/lingo/lingo-gr.y"
+#line 119 "engines/director/lingo/lingo-gr.y"
{ g_lingo->code1(g_lingo->c_xpop); ;}
break;
case 12:
-#line 121 "engines/director/lingo/lingo-gr.y"
+#line 123 "engines/director/lingo/lingo-gr.y"
{
g_lingo->code1(g_lingo->c_varpush);
g_lingo->codeString((yyvsp[(4) - (4)].s)->c_str());
@@ -1886,7 +1897,7 @@ yyreduce:
break;
case 13:
-#line 127 "engines/director/lingo/lingo-gr.y"
+#line 129 "engines/director/lingo/lingo-gr.y"
{
g_lingo->code1(g_lingo->c_varpush);
g_lingo->codeString((yyvsp[(2) - (4)].s)->c_str());
@@ -1896,7 +1907,7 @@ yyreduce:
break;
case 14:
-#line 133 "engines/director/lingo/lingo-gr.y"
+#line 135 "engines/director/lingo/lingo-gr.y"
{
g_lingo->codeConst(0); // Put dummy id
g_lingo->code1(g_lingo->c_theentityassign);
@@ -1908,7 +1919,7 @@ yyreduce:
break;
case 15:
-#line 141 "engines/director/lingo/lingo-gr.y"
+#line 143 "engines/director/lingo/lingo-gr.y"
{
g_lingo->code1(g_lingo->c_swap);
g_lingo->code1(g_lingo->c_theentityassign);
@@ -1920,7 +1931,7 @@ yyreduce:
break;
case 16:
-#line 149 "engines/director/lingo/lingo-gr.y"
+#line 151 "engines/director/lingo/lingo-gr.y"
{
g_lingo->code1(g_lingo->c_varpush);
g_lingo->codeString((yyvsp[(2) - (4)].s)->c_str());
@@ -1930,7 +1941,7 @@ yyreduce:
break;
case 17:
-#line 155 "engines/director/lingo/lingo-gr.y"
+#line 157 "engines/director/lingo/lingo-gr.y"
{
g_lingo->codeConst(0); // Put dummy id
g_lingo->code1(g_lingo->c_theentityassign);
@@ -1942,7 +1953,7 @@ yyreduce:
break;
case 18:
-#line 163 "engines/director/lingo/lingo-gr.y"
+#line 165 "engines/director/lingo/lingo-gr.y"
{
g_lingo->code1(g_lingo->c_swap);
g_lingo->code1(g_lingo->c_theentityassign);
@@ -1954,12 +1965,12 @@ yyreduce:
break;
case 19:
-#line 172 "engines/director/lingo/lingo-gr.y"
+#line 174 "engines/director/lingo/lingo-gr.y"
{ g_lingo->code1(g_lingo->c_xpop); ;}
break;
case 23:
-#line 181 "engines/director/lingo/lingo-gr.y"
+#line 183 "engines/director/lingo/lingo-gr.y"
{
inst body = 0, end = 0;
WRITE_UINT32(&body, (yyvsp[(5) - (8)].code));
@@ -1969,7 +1980,7 @@ yyreduce:
break;
case 24:
-#line 192 "engines/director/lingo/lingo-gr.y"
+#line 194 "engines/director/lingo/lingo-gr.y"
{
inst init = 0, finish = 0, body = 0, end = 0, inc = 0;
WRITE_UINT32(&init, (yyvsp[(3) - (11)].code));
@@ -1985,7 +1996,7 @@ yyreduce:
break;
case 25:
-#line 208 "engines/director/lingo/lingo-gr.y"
+#line 210 "engines/director/lingo/lingo-gr.y"
{
inst init = 0, finish = 0, body = 0, end = 0, inc = 0;
WRITE_UINT32(&init, (yyvsp[(3) - (12)].code));
@@ -2001,7 +2012,7 @@ yyreduce:
break;
case 26:
-#line 220 "engines/director/lingo/lingo-gr.y"
+#line 222 "engines/director/lingo/lingo-gr.y"
{
inst end = 0;
WRITE_UINT32(&end, (yyvsp[(3) - (3)].code));
@@ -2011,7 +2022,7 @@ yyreduce:
break;
case 27:
-#line 228 "engines/director/lingo/lingo-gr.y"
+#line 230 "engines/director/lingo/lingo-gr.y"
{
inst then = 0, end = 0;
WRITE_UINT32(&then, (yyvsp[(5) - (8)].code));
@@ -2022,7 +2033,7 @@ yyreduce:
break;
case 28:
-#line 235 "engines/director/lingo/lingo-gr.y"
+#line 237 "engines/director/lingo/lingo-gr.y"
{
inst then = 0, else1 = 0, end = 0;
WRITE_UINT32(&then, (yyvsp[(5) - (11)].code));
@@ -2035,7 +2046,7 @@ yyreduce:
break;
case 29:
-#line 244 "engines/director/lingo/lingo-gr.y"
+#line 246 "engines/director/lingo/lingo-gr.y"
{
inst then = 0, else1 = 0, end = 0;
WRITE_UINT32(&then, (yyvsp[(5) - (11)].code));
@@ -2048,7 +2059,7 @@ yyreduce:
break;
case 30:
-#line 253 "engines/director/lingo/lingo-gr.y"
+#line 255 "engines/director/lingo/lingo-gr.y"
{
inst then = 0, else1 = 0, end = 0;
WRITE_UINT32(&then, (yyvsp[(4) - (6)].code));
@@ -2062,7 +2073,7 @@ yyreduce:
break;
case 31:
-#line 263 "engines/director/lingo/lingo-gr.y"
+#line 265 "engines/director/lingo/lingo-gr.y"
{
inst then = 0, else1 = 0, end = 0;
WRITE_UINT32(&then, (yyvsp[(4) - (10)].code));
@@ -2076,7 +2087,7 @@ yyreduce:
break;
case 32:
-#line 273 "engines/director/lingo/lingo-gr.y"
+#line 275 "engines/director/lingo/lingo-gr.y"
{
inst then = 0, else1 = 0, end = 0;
WRITE_UINT32(&then, (yyvsp[(4) - (10)].code));
@@ -2090,17 +2101,17 @@ yyreduce:
break;
case 33:
-#line 284 "engines/director/lingo/lingo-gr.y"
+#line 286 "engines/director/lingo/lingo-gr.y"
{ (yyval.code) = 0; ;}
break;
case 34:
-#line 285 "engines/director/lingo/lingo-gr.y"
+#line 287 "engines/director/lingo/lingo-gr.y"
{ (yyval.code) = (yyvsp[(2) - (3)].code); ;}
break;
case 39:
-#line 296 "engines/director/lingo/lingo-gr.y"
+#line 298 "engines/director/lingo/lingo-gr.y"
{
inst then = 0;
WRITE_UINT32(&then, (yyvsp[(4) - (6)].code));
@@ -2110,7 +2121,7 @@ yyreduce:
break;
case 41:
-#line 305 "engines/director/lingo/lingo-gr.y"
+#line 307 "engines/director/lingo/lingo-gr.y"
{
inst then = 0;
WRITE_UINT32(&then, (yyvsp[(4) - (5)].code));
@@ -2120,22 +2131,22 @@ yyreduce:
break;
case 42:
-#line 313 "engines/director/lingo/lingo-gr.y"
+#line 315 "engines/director/lingo/lingo-gr.y"
{ g_lingo->code1(STOP); ;}
break;
case 43:
-#line 314 "engines/director/lingo/lingo-gr.y"
+#line 316 "engines/director/lingo/lingo-gr.y"
{ g_lingo->code2(g_lingo->c_eq, STOP); ;}
break;
case 45:
-#line 317 "engines/director/lingo/lingo-gr.y"
+#line 319 "engines/director/lingo/lingo-gr.y"
{ (yyval.code) = g_lingo->code3(g_lingo->c_repeatwhilecode, STOP, STOP); ;}
break;
case 46:
-#line 319 "engines/director/lingo/lingo-gr.y"
+#line 321 "engines/director/lingo/lingo-gr.y"
{
(yyval.code) = g_lingo->code3(g_lingo->c_repeatwithcode, STOP, STOP);
g_lingo->code3(STOP, STOP, STOP);
@@ -2144,7 +2155,7 @@ yyreduce:
break;
case 47:
-#line 325 "engines/director/lingo/lingo-gr.y"
+#line 327 "engines/director/lingo/lingo-gr.y"
{
(yyval.code) = g_lingo->code1(g_lingo->c_ifcode);
g_lingo->code3(STOP, STOP, STOP);
@@ -2153,7 +2164,7 @@ yyreduce:
break;
case 48:
-#line 331 "engines/director/lingo/lingo-gr.y"
+#line 333 "engines/director/lingo/lingo-gr.y"
{
inst skipEnd;
WRITE_UINT32(&skipEnd, 1); // We have to skip end to avoid multiple executions
@@ -2163,22 +2174,22 @@ yyreduce:
break;
case 49:
-#line 338 "engines/director/lingo/lingo-gr.y"
+#line 340 "engines/director/lingo/lingo-gr.y"
{ (yyval.code) = g_lingo->_currentScript->size(); ;}
break;
case 50:
-#line 340 "engines/director/lingo/lingo-gr.y"
+#line 342 "engines/director/lingo/lingo-gr.y"
{ g_lingo->code1(STOP); (yyval.code) = g_lingo->_currentScript->size(); ;}
break;
case 51:
-#line 342 "engines/director/lingo/lingo-gr.y"
+#line 344 "engines/director/lingo/lingo-gr.y"
{ (yyval.code) = g_lingo->_currentScript->size(); ;}
break;
case 54:
-#line 347 "engines/director/lingo/lingo-gr.y"
+#line 349 "engines/director/lingo/lingo-gr.y"
{
(yyval.code) = g_lingo->code1(g_lingo->c_whencode);
g_lingo->code1(STOP);
@@ -2187,26 +2198,26 @@ yyreduce:
break;
case 55:
-#line 353 "engines/director/lingo/lingo-gr.y"
+#line 355 "engines/director/lingo/lingo-gr.y"
{ (yyval.code) = g_lingo->codeConst((yyvsp[(1) - (1)].i)); ;}
break;
case 56:
-#line 354 "engines/director/lingo/lingo-gr.y"
+#line 356 "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 357 "engines/director/lingo/lingo-gr.y"
+#line 359 "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 360 "engines/director/lingo/lingo-gr.y"
+#line 362 "engines/director/lingo/lingo-gr.y"
{
(yyval.code) = g_lingo->code1(g_lingo->_handlers[*(yyvsp[(1) - (1)].s)]->u.func);
g_lingo->codeConst(0); // Put dummy value
@@ -2214,14 +2225,14 @@ yyreduce:
break;
case 59:
-#line 364 "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 367 "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());
@@ -2229,7 +2240,7 @@ yyreduce:
break;
case 61:
-#line 371 "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);
@@ -2240,7 +2251,7 @@ yyreduce:
break;
case 62:
-#line 378 "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;
@@ -2250,131 +2261,129 @@ yyreduce:
break;
case 64:
-#line 385 "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 386 "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 387 "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 388 "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 389 "engines/director/lingo/lingo-gr.y"
- { g_lingo->code1(g_lingo->c_gt); ;}
+#line 391 "engines/director/lingo/lingo-gr.y"
+ { g_lingo->code1(g_lingo->c_mod); ;}
break;
case 69:
-#line 390 "engines/director/lingo/lingo-gr.y"
- { g_lingo->code1(g_lingo->c_lt); ;}
+#line 392 "engines/director/lingo/lingo-gr.y"
+ { g_lingo->code1(g_lingo->c_gt); ;}
break;
case 70:
-#line 391 "engines/director/lingo/lingo-gr.y"
- { g_lingo->code1(g_lingo->c_neq); ;}
+#line 393 "engines/director/lingo/lingo-gr.y"
+ { g_lingo->code1(g_lingo->c_lt); ;}
break;
case 71:
-#line 392 "engines/director/lingo/lingo-gr.y"
- { g_lingo->code1(g_lingo->c_ge); ;}
+#line 394 "engines/director/lingo/lingo-gr.y"
+ { g_lingo->code1(g_lingo->c_neq); ;}
break;
case 72:
-#line 393 "engines/director/lingo/lingo-gr.y"
- { g_lingo->code1(g_lingo->c_le); ;}
+#line 395 "engines/director/lingo/lingo-gr.y"
+ { g_lingo->code1(g_lingo->c_ge); ;}
break;
case 73:
-#line 394 "engines/director/lingo/lingo-gr.y"
- { g_lingo->code1(g_lingo->c_and); ;}
+#line 396 "engines/director/lingo/lingo-gr.y"
+ { g_lingo->code1(g_lingo->c_le); ;}
break;
case 74:
-#line 395 "engines/director/lingo/lingo-gr.y"
- { g_lingo->code1(g_lingo->c_or); ;}
+#line 397 "engines/director/lingo/lingo-gr.y"
+ { g_lingo->code1(g_lingo->c_and); ;}
break;
case 75:
-#line 396 "engines/director/lingo/lingo-gr.y"
- { g_lingo->code1(g_lingo->c_not); ;}
+#line 398 "engines/director/lingo/lingo-gr.y"
+ { g_lingo->code1(g_lingo->c_or); ;}
break;
case 76:
-#line 397 "engines/director/lingo/lingo-gr.y"
- { g_lingo->code1(g_lingo->c_ampersand); ;}
+#line 399 "engines/director/lingo/lingo-gr.y"
+ { g_lingo->code1(g_lingo->c_not); ;}
break;
case 77:
-#line 398 "engines/director/lingo/lingo-gr.y"
- { g_lingo->code1(g_lingo->c_concat); ;}
+#line 400 "engines/director/lingo/lingo-gr.y"
+ { g_lingo->code1(g_lingo->c_ampersand); ;}
break;
case 78:
-#line 399 "engines/director/lingo/lingo-gr.y"
- { g_lingo->code1(g_lingo->c_contains); ;}
+#line 401 "engines/director/lingo/lingo-gr.y"
+ { g_lingo->code1(g_lingo->c_concat); ;}
break;
case 79:
-#line 400 "engines/director/lingo/lingo-gr.y"
- { g_lingo->code1(g_lingo->c_starts); ;}
+#line 402 "engines/director/lingo/lingo-gr.y"
+ { g_lingo->code1(g_lingo->c_contains); ;}
break;
case 80:
-#line 401 "engines/director/lingo/lingo-gr.y"
- { (yyval.code) = (yyvsp[(2) - (2)].code); ;}
+#line 403 "engines/director/lingo/lingo-gr.y"
+ { g_lingo->code1(g_lingo->c_starts); ;}
break;
case 81:
-#line 402 "engines/director/lingo/lingo-gr.y"
- { (yyval.code) = (yyvsp[(2) - (2)].code); g_lingo->code1(g_lingo->c_negate); ;}
+#line 404 "engines/director/lingo/lingo-gr.y"
+ { (yyval.code) = (yyvsp[(2) - (2)].code); ;}
break;
case 82:
-#line 403 "engines/director/lingo/lingo-gr.y"
- { (yyval.code) = (yyvsp[(2) - (3)].code); ;}
+#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 404 "engines/director/lingo/lingo-gr.y"
- { g_lingo->code1(g_lingo->c_intersects); ;}
+#line 406 "engines/director/lingo/lingo-gr.y"
+ { (yyval.code) = (yyvsp[(2) - (3)].code); ;}
break;
case 84:
-#line 405 "engines/director/lingo/lingo-gr.y"
- { g_lingo->code1(g_lingo->c_within); ;}
+#line 407 "engines/director/lingo/lingo-gr.y"
+ { g_lingo->code1(g_lingo->c_intersects); ;}
break;
case 85:
#line 408 "engines/director/lingo/lingo-gr.y"
- { g_lingo->code1(g_lingo->c_printtop); ;}
+ { g_lingo->code1(g_lingo->c_within); ;}
break;
- case 88:
+ case 86:
#line 411 "engines/director/lingo/lingo-gr.y"
- { g_lingo->code1(g_lingo->c_exitRepeat); ;}
+ { g_lingo->code1(g_lingo->c_printtop); ;}
break;
case 89:
-#line 412 "engines/director/lingo/lingo-gr.y"
- { g_lingo->codeConst(0); // Push fake value on stack
- g_lingo->code1(g_lingo->c_procret); ;}
+#line 414 "engines/director/lingo/lingo-gr.y"
+ { g_lingo->code1(g_lingo->c_exitRepeat); ;}
break;
- case 92:
-#line 416 "engines/director/lingo/lingo-gr.y"
- {
- g_lingo->code1(g_lingo->_handlers[*(yyvsp[(1) - (2)].s)]->u.func);
- delete (yyvsp[(1) - (2)].s); ;}
+ case 90:
+#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:
@@ -2387,114 +2396,121 @@ yyreduce:
case 94:
#line 422 "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); ;}
+ g_lingo->code1(g_lingo->_handlers[*(yyvsp[(1) - (2)].s)]->u.func);
+ delete (yyvsp[(1) - (2)].s); ;}
break;
case 95:
#line 425 "engines/director/lingo/lingo-gr.y"
- { g_lingo->codeFunc((yyvsp[(1) - (2)].s), (yyvsp[(2) - (2)].narg)); ;}
+ {
+ 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 426 "engines/director/lingo/lingo-gr.y"
- { g_lingo->code1(g_lingo->c_open); ;}
+#line 428 "engines/director/lingo/lingo-gr.y"
+ { g_lingo->codeFunc((yyvsp[(1) - (2)].s), (yyvsp[(2) - (2)].narg)); ;}
break;
case 97:
-#line 427 "engines/director/lingo/lingo-gr.y"
- { g_lingo->code2(g_lingo->c_voidpush, g_lingo->c_open); ;}
+#line 429 "engines/director/lingo/lingo-gr.y"
+ { g_lingo->code1(g_lingo->c_open); ;}
break;
case 98:
#line 430 "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); ;}
+ { g_lingo->code2(g_lingo->c_voidpush, g_lingo->c_open); ;}
break;
case 99:
-#line 431 "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); ;}
+#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 434 "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); ;}
+ { 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 435 "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); ;}
+#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 446 "engines/director/lingo/lingo-gr.y"
- { g_lingo->code1(g_lingo->c_gotoloop); ;}
+#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 447 "engines/director/lingo/lingo-gr.y"
- { g_lingo->code1(g_lingo->c_gotonext); ;}
+#line 449 "engines/director/lingo/lingo-gr.y"
+ { g_lingo->code1(g_lingo->c_gotoloop); ;}
break;
case 104:
-#line 448 "engines/director/lingo/lingo-gr.y"
- { g_lingo->code1(g_lingo->c_gotoprevious); ;}
+#line 450 "engines/director/lingo/lingo-gr.y"
+ { g_lingo->code1(g_lingo->c_gotonext); ;}
break;
case 105:
-#line 449 "engines/director/lingo/lingo-gr.y"
- {
- g_lingo->codeConst(1);
- g_lingo->code1(g_lingo->c_goto); ;}
+#line 451 "engines/director/lingo/lingo-gr.y"
+ { g_lingo->code1(g_lingo->c_gotoprevious); ;}
break;
case 106:
#line 452 "engines/director/lingo/lingo-gr.y"
{
- g_lingo->codeConst(3);
+ g_lingo->codeConst(1);
g_lingo->code1(g_lingo->c_goto); ;}
break;
case 107:
#line 455 "engines/director/lingo/lingo-gr.y"
{
+ g_lingo->codeConst(3);
+ g_lingo->code1(g_lingo->c_goto); ;}
+ break;
+
+ case 108:
+#line 458 "engines/director/lingo/lingo-gr.y"
+ {
g_lingo->codeConst(2);
g_lingo->code1(g_lingo->c_goto); ;}
break;
- case 112:
-#line 468 "engines/director/lingo/lingo-gr.y"
+ case 113:
+#line 471 "engines/director/lingo/lingo-gr.y"
{ g_lingo->code1(g_lingo->c_playdone); ;}
break;
- case 113:
-#line 469 "engines/director/lingo/lingo-gr.y"
+ case 114:
+#line 472 "engines/director/lingo/lingo-gr.y"
{
g_lingo->codeConst(1);
g_lingo->code1(g_lingo->c_play); ;}
break;
- case 114:
-#line 472 "engines/director/lingo/lingo-gr.y"
+ case 115:
+#line 475 "engines/director/lingo/lingo-gr.y"
{
g_lingo->codeConst(3);
g_lingo->code1(g_lingo->c_play); ;}
break;
- case 115:
-#line 475 "engines/director/lingo/lingo-gr.y"
+ case 116:
+#line 478 "engines/director/lingo/lingo-gr.y"
{
g_lingo->codeConst(2);
g_lingo->code1(g_lingo->c_play); ;}
break;
- case 116:
-#line 505 "engines/director/lingo/lingo-gr.y"
+ case 117:
+#line 508 "engines/director/lingo/lingo-gr.y"
{ g_lingo->_indef = true; g_lingo->_currentFactory.clear(); ;}
break;
- case 117:
-#line 506 "engines/director/lingo/lingo-gr.y"
+ case 118:
+#line 509 "engines/director/lingo/lingo-gr.y"
{
g_lingo->codeConst(0); // Push fake value on stack
g_lingo->code1(g_lingo->c_procret);
@@ -2502,53 +2518,53 @@ yyreduce:
g_lingo->_indef = false; ;}
break;
- case 118:
-#line 511 "engines/director/lingo/lingo-gr.y"
+ case 119:
+#line 514 "engines/director/lingo/lingo-gr.y"
{
g_lingo->codeFactory(*(yyvsp[(2) - (2)].s));
;}
break;
- case 119:
-#line 514 "engines/director/lingo/lingo-gr.y"
+ case 120:
+#line 517 "engines/director/lingo/lingo-gr.y"
{ g_lingo->_indef = true; ;}
break;
- case 120:
-#line 515 "engines/director/lingo/lingo-gr.y"
+ case 121:
+#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);
g_lingo->_indef = false; ;}
break;
- case 121:
-#line 519 "engines/director/lingo/lingo-gr.y"
+ case 122:
+#line 522 "engines/director/lingo/lingo-gr.y"
{ (yyval.narg) = 0; ;}
break;
- case 122:
-#line 520 "engines/director/lingo/lingo-gr.y"
+ case 123:
+#line 523 "engines/director/lingo/lingo-gr.y"
{ g_lingo->codeArg((yyvsp[(1) - (1)].s)); (yyval.narg) = 1; ;}
break;
- case 123:
-#line 521 "engines/director/lingo/lingo-gr.y"
+ case 124:
+#line 524 "engines/director/lingo/lingo-gr.y"
{ g_lingo->codeArg((yyvsp[(3) - (3)].s)); (yyval.narg) = (yyvsp[(1) - (3)].narg) + 1; ;}
break;
- case 124:
-#line 522 "engines/director/lingo/lingo-gr.y"
+ case 125:
+#line 525 "engines/director/lingo/lingo-gr.y"
{ g_lingo->codeArg((yyvsp[(4) - (4)].s)); (yyval.narg) = (yyvsp[(1) - (4)].narg) + 1; ;}
break;
- case 125:
-#line 524 "engines/director/lingo/lingo-gr.y"
+ case 126:
+#line 527 "engines/director/lingo/lingo-gr.y"
{ g_lingo->codeArgStore(); ;}
break;
- case 126:
-#line 528 "engines/director/lingo/lingo-gr.y"
+ case 127:
+#line 531 "engines/director/lingo/lingo-gr.y"
{
g_lingo->code1(g_lingo->c_call);
g_lingo->codeString((yyvsp[(1) - (3)].s)->c_str());
@@ -2557,24 +2573,24 @@ yyreduce:
g_lingo->code1(numpar); ;}
break;
- case 127:
-#line 536 "engines/director/lingo/lingo-gr.y"
+ case 128:
+#line 539 "engines/director/lingo/lingo-gr.y"
{ (yyval.narg) = 0; ;}
break;
- case 128:
-#line 537 "engines/director/lingo/lingo-gr.y"
+ case 129:
+#line 540 "engines/director/lingo/lingo-gr.y"
{ (yyval.narg) = 1; ;}
break;
- case 129:
-#line 538 "engines/director/lingo/lingo-gr.y"
+ case 130:
+#line 541 "engines/director/lingo/lingo-gr.y"
{ (yyval.narg) = (yyvsp[(1) - (3)].narg) + 1; ;}
break;
/* Line 1267 of yacc.c. */
-#line 2578 "engines/director/lingo/lingo-gr.cpp"
+#line 2594 "engines/director/lingo/lingo-gr.cpp"
default: break;
}
YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc);
@@ -2788,6 +2804,6 @@ yyreturn:
}
-#line 541 "engines/director/lingo/lingo-gr.y"
+#line 544 "engines/director/lingo/lingo-gr.y"
diff --git a/engines/director/lingo/lingo-gr.h b/engines/director/lingo/lingo-gr.h
index 34e311c01e..46097085fe 100644
--- a/engines/director/lingo/lingo-gr.h
+++ b/engines/director/lingo/lingo-gr.h
@@ -101,12 +101,13 @@
tAND = 317,
tOR = 318,
tNOT = 319,
- tCONCAT = 320,
- tCONTAINS = 321,
- tSTARTS = 322,
- tSPRITE = 323,
- tINTERSECTS = 324,
- tWITHIN = 325
+ tMOD = 320,
+ tCONCAT = 321,
+ tCONTAINS = 322,
+ tSTARTS = 323,
+ tSPRITE = 324,
+ tINTERSECTS = 325,
+ tWITHIN = 326
};
#endif
/* Tokens. */
@@ -172,12 +173,13 @@
#define tAND 317
#define tOR 318
#define tNOT 319
-#define tCONCAT 320
-#define tCONTAINS 321
-#define tSTARTS 322
-#define tSPRITE 323
-#define tINTERSECTS 324
-#define tWITHIN 325
+#define tMOD 320
+#define tCONCAT 321
+#define tCONTAINS 322
+#define tSTARTS 323
+#define tSPRITE 324
+#define tINTERSECTS 325
+#define tWITHIN 326
@@ -195,7 +197,7 @@ typedef union YYSTYPE
Common::Array<double> *arr;
}
/* Line 1529 of yacc.c. */
-#line 199 "engines/director/lingo/lingo-gr.hpp"
+#line 201 "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 8fa273b57d..d3b9312adb 100644
--- a/engines/director/lingo/lingo-gr.y
+++ b/engines/director/lingo/lingo-gr.y
@@ -86,7 +86,7 @@ void yyerror(char *s) {
%token tDOWN tELSE tNLELSIF tEND tEXIT tFRAME tGLOBAL tGO tIF tINTO tLOOP tMACRO
%token tMOVIE tNEXT tOF tPREVIOUS tPUT tREPEAT tSET tTHEN tTO tWHEN
%token tWITH tWHILE tNLELSE tFACTORY tMETHOD tOPEN tPLAY tDONE tPLAYACCEL tINSTANCE
-%token tGE tLE tGT tLT tEQ tNEQ tAND tOR tNOT
+%token tGE tLE tGT tLT tEQ tNEQ tAND tOR tNOT tMOD
%token tCONCAT tCONTAINS tSTARTS
%token tSPRITE tINTERSECTS tWITHIN
@@ -94,8 +94,10 @@ void yyerror(char *s) {
%type<narg> argdef arglist
%right '='
+%left tLT tLE tGT tGE tNEQ tCONTAINS tSTARTS
+%left '&'
%left '+' '-'
-%left '*' '/' '%'
+%left '*' '/' '%' tAND tOR tMOD
%right UNARY
%%
@@ -386,6 +388,7 @@ expr: INT { $$ = g_lingo->codeConst($1); }
| expr '-' expr { g_lingo->code1(g_lingo->c_sub); }
| expr '*' expr { g_lingo->code1(g_lingo->c_mul); }
| expr '/' expr { g_lingo->code1(g_lingo->c_div); }
+ | expr tMOD expr { g_lingo->code1(g_lingo->c_mod); }
| expr '>' expr { g_lingo->code1(g_lingo->c_gt); }
| expr '<' expr { g_lingo->code1(g_lingo->c_lt); }
| expr tNEQ expr { g_lingo->code1(g_lingo->c_neq); }
diff --git a/engines/director/lingo/lingo-lex.cpp b/engines/director/lingo/lingo-lex.cpp
index 426c6ced92..ebdb169a65 100644
--- a/engines/director/lingo/lingo-lex.cpp
+++ b/engines/director/lingo/lingo-lex.cpp
@@ -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 58
-#define YY_END_OF_BUFFER 59
+#define YY_NUM_RULES 59
+#define YY_END_OF_BUFFER 60
/* 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[205] =
+static yyconst flex_int16_t yy_accept[206] =
{ 0,
- 0, 0, 59, 57, 3, 55, 55, 57, 57, 54,
- 54, 54, 53, 54, 54, 51, 51, 51, 51, 51,
- 51, 51, 51, 51, 51, 51, 51, 51, 51, 51,
- 51, 51, 2, 2, 3, 55, 0, 0, 0, 0,
- 0, 56, 50, 1, 52, 53, 49, 47, 48, 51,
- 51, 51, 51, 51, 51, 51, 51, 51, 51, 18,
- 8, 51, 51, 51, 51, 51, 51, 51, 28, 51,
- 30, 51, 51, 51, 51, 51, 51, 51, 51, 41,
- 51, 51, 2, 2, 0, 1, 52, 4, 51, 51,
- 51, 51, 12, 51, 51, 51, 51, 0, 51, 51,
-
- 51, 51, 51, 51, 51, 27, 51, 51, 51, 33,
- 51, 35, 51, 51, 51, 51, 51, 51, 0, 51,
- 6, 7, 11, 14, 51, 51, 51, 0, 51, 51,
- 21, 22, 51, 51, 51, 26, 29, 31, 51, 51,
- 51, 51, 0, 40, 45, 51, 43, 10, 51, 51,
- 15, 51, 17, 51, 51, 23, 51, 25, 51, 51,
- 51, 51, 39, 39, 46, 51, 0, 51, 51, 16,
- 51, 51, 24, 51, 34, 42, 36, 0, 39, 44,
- 0, 51, 13, 51, 51, 51, 0, 39, 9, 5,
- 19, 51, 32, 0, 39, 51, 0, 0, 20, 38,
-
- 0, 0, 37, 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
} ;
static yyconst flex_int32_t yy_ec[256] =
@@ -443,61 +443,61 @@ static yyconst flex_int32_t yy_meta[63] =
5, 5
} ;
-static yyconst flex_int16_t yy_base[210] =
+static yyconst flex_int16_t yy_base[211] =
{ 0,
- 0, 61, 156, 516, 65, 69, 73, 77, 148, 516,
+ 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, 516, 189, 193, 197, 106,
- 94, 516, 516, 0, 82, 132, 516, 516, 516, 0,
+ 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, 183, 182, 188, 0, 204,
- 0, 209, 206, 194, 201, 203, 209, 229, 227, 0,
- 233, 222, 263, 270, 226, 0, 80, 0, 226, 234,
- 234, 243, 0, 237, 243, 254, 247, 284, 251, 271,
-
- 263, 264, 271, 273, 265, 0, 274, 264, 268, 0,
- 286, 0, 283, 278, 305, 284, 287, 291, 295, 305,
- 0, 0, 0, 0, 296, 309, 314, 306, 322, 309,
- 0, 0, 314, 315, 325, 0, 0, 0, 323, 332,
- 316, 317, 350, 0, 0, 332, 336, 202, 337, 326,
- 0, 338, 516, 338, 336, 0, 343, 0, 342, 342,
- 358, 347, 212, 378, 0, 361, 388, 364, 357, 0,
- 379, 378, 0, 366, 0, 0, 0, 399, 408, 0,
- 378, 373, 0, 390, 399, 375, 397, 423, 516, 0,
- 0, 381, 0, 428, 435, 388, 441, 443, 0, 445,
-
- 415, 447, 452, 516, 495, 497, 502, 506, 510
+ 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
} ;
-static yyconst flex_int16_t yy_def[210] =
+static yyconst flex_int16_t yy_def[211] =
{ 0,
- 204, 1, 204, 204, 204, 204, 204, 204, 205, 204,
- 204, 204, 204, 204, 204, 206, 206, 206, 206, 206,
- 206, 206, 206, 206, 206, 206, 206, 206, 206, 206,
- 206, 206, 204, 204, 204, 204, 204, 204, 204, 204,
- 205, 204, 204, 207, 204, 204, 204, 204, 204, 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, 204, 204, 204, 207, 204, 206, 206, 206,
- 206, 206, 206, 206, 206, 206, 206, 204, 206, 206,
-
- 206, 206, 206, 206, 206, 206, 206, 206, 206, 206,
- 206, 206, 206, 206, 206, 206, 206, 206, 204, 206,
- 206, 206, 206, 206, 206, 206, 206, 204, 206, 206,
- 206, 206, 206, 206, 206, 206, 206, 206, 206, 206,
- 206, 206, 208, 206, 206, 206, 206, 204, 206, 206,
- 206, 206, 204, 206, 206, 206, 206, 206, 206, 206,
- 206, 206, 208, 208, 206, 206, 204, 206, 206, 206,
- 206, 206, 206, 206, 206, 206, 206, 204, 208, 206,
- 204, 206, 206, 206, 206, 206, 204, 208, 204, 206,
- 206, 206, 206, 204, 208, 206, 209, 204, 206, 209,
-
- 204, 204, 209, 0, 204, 204, 204, 204, 204
+ 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
} ;
-static yyconst flex_int16_t yy_nxt[579] =
+static yyconst flex_int16_t yy_nxt[584] =
{ 0,
4, 5, 6, 7, 8, 9, 10, 11, 12, 4,
13, 14, 10, 15, 16, 17, 18, 19, 20, 21,
@@ -515,56 +515,57 @@ static yyconst flex_int16_t yy_nxt[579] =
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, 204, 68, 70, 72, 71,
- 204, 76, 93, 79, 73, 204, 204, 74, 80, 89,
- 77, 92, 98, 204, 78, 98, 81, 82, 83, 36,
+ 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, 167, 91, 96, 167, 97, 99, 100,
- 101, 40, 102, 178, 103, 40, 178, 104, 105, 90,
- 106, 94, 107, 108, 109, 204, 110, 95, 91, 111,
- 96, 97, 99, 100, 101, 112, 40, 102, 103, 113,
- 40, 104, 105, 114, 106, 115, 204, 107, 108, 109,
- 110, 116, 121, 111, 118, 117, 204, 119, 120, 112,
- 122, 123, 127, 113, 83, 36, 36, 84, 114, 124,
- 115, 84, 36, 36, 84, 125, 116, 121, 118, 126,
- 117, 119, 120, 129, 122, 98, 123, 127, 98, 130,
- 204, 132, 134, 124, 133, 135, 204, 136, 131, 125,
-
- 137, 138, 139, 126, 140, 141, 143, 129, 142, 143,
- 145, 146, 147, 148, 130, 132, 128, 134, 133, 149,
- 135, 136, 131, 150, 137, 138, 139, 151, 152, 140,
- 141, 144, 142, 153, 145, 146, 154, 147, 148, 155,
- 128, 156, 157, 158, 149, 159, 160, 150, 161, 162,
- 165, 143, 151, 152, 143, 144, 169, 153, 166, 168,
- 173, 154, 170, 155, 171, 156, 157, 172, 158, 174,
- 159, 160, 161, 162, 175, 165, 176, 204, 177, 178,
- 169, 164, 178, 166, 168, 173, 170, 180, 171, 167,
- 182, 172, 167, 174, 183, 184, 185, 189, 175, 186,
-
- 178, 176, 177, 178, 190, 164, 193, 179, 191, 178,
- 181, 180, 178, 196, 182, 192, 194, 204, 183, 199,
- 184, 185, 189, 186, 178, 204, 187, 178, 190, 197,
- 193, 179, 197, 191, 202, 181, 198, 196, 188, 198,
- 192, 194, 197, 199, 198, 197, 204, 198, 203, 204,
- 187, 203, 204, 203, 204, 195, 203, 204, 204, 202,
- 204, 204, 188, 204, 204, 204, 204, 204, 204, 204,
- 201, 204, 204, 204, 204, 204, 204, 204, 204, 195,
- 204, 204, 204, 204, 204, 204, 204, 204, 204, 204,
- 204, 204, 204, 204, 201, 41, 41, 204, 41, 41,
-
- 50, 50, 86, 86, 204, 86, 86, 163, 204, 204,
- 163, 200, 204, 204, 200, 3, 204, 204, 204, 204,
- 204, 204, 204, 204, 204, 204, 204, 204, 204, 204,
- 204, 204, 204, 204, 204, 204, 204, 204, 204, 204,
- 204, 204, 204, 204, 204, 204, 204, 204, 204, 204,
- 204, 204, 204, 204, 204, 204, 204, 204, 204, 204,
- 204, 204, 204, 204, 204, 204, 204, 204, 204, 204,
- 204, 204, 204, 204, 204, 204, 204, 204
+ 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
} ;
-static yyconst flex_int16_t yy_chk[579] =
+static yyconst flex_int16_t yy_chk[584] =
{ 0,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
@@ -588,47 +589,48 @@ static yyconst flex_int16_t yy_chk[579] =
33, 33, 34, 34, 34, 34, 35, 35, 35, 35,
37, 37, 37, 37, 38, 53, 56, 38, 39, 39,
- 39, 39, 57, 148, 53, 58, 148, 59, 62, 62,
- 63, 38, 64, 163, 65, 39, 163, 66, 67, 53,
+ 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, 76, 38, 64, 65, 77,
- 39, 66, 67, 78, 68, 79, 0, 70, 72, 73,
- 74, 81, 90, 75, 82, 81, 0, 85, 89, 76,
- 91, 92, 97, 77, 83, 83, 83, 83, 78, 94,
- 79, 84, 84, 84, 84, 95, 81, 90, 82, 96,
- 81, 85, 89, 99, 91, 98, 92, 97, 98, 100,
- 0, 101, 103, 94, 102, 104, 0, 105, 100, 95,
-
- 107, 108, 109, 96, 111, 113, 115, 99, 114, 115,
- 116, 117, 118, 119, 100, 101, 98, 103, 102, 120,
- 104, 105, 100, 125, 107, 108, 109, 126, 127, 111,
- 113, 115, 114, 128, 116, 117, 129, 118, 119, 130,
- 98, 133, 134, 135, 120, 139, 140, 125, 141, 142,
- 146, 143, 126, 127, 143, 115, 150, 128, 147, 149,
- 157, 129, 152, 130, 154, 133, 134, 155, 135, 159,
- 139, 140, 141, 142, 160, 146, 161, 0, 162, 164,
- 150, 143, 164, 147, 149, 157, 152, 166, 154, 167,
- 168, 155, 167, 159, 169, 171, 172, 181, 160, 174,
-
- 178, 161, 162, 178, 182, 143, 186, 164, 184, 179,
- 167, 166, 179, 192, 168, 185, 187, 0, 169, 196,
- 171, 172, 181, 174, 188, 0, 178, 188, 182, 194,
- 186, 164, 194, 184, 201, 167, 195, 192, 179, 195,
- 185, 187, 197, 196, 198, 197, 200, 198, 202, 200,
- 178, 202, 0, 203, 0, 188, 203, 0, 0, 201,
- 0, 0, 179, 0, 0, 0, 0, 0, 0, 0,
- 198, 0, 0, 0, 0, 0, 0, 0, 0, 188,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 198, 205, 205, 0, 205, 205,
-
- 206, 206, 207, 207, 0, 207, 207, 208, 0, 0,
- 208, 209, 0, 0, 209, 204, 204, 204, 204, 204,
- 204, 204, 204, 204, 204, 204, 204, 204, 204, 204,
- 204, 204, 204, 204, 204, 204, 204, 204, 204, 204,
- 204, 204, 204, 204, 204, 204, 204, 204, 204, 204,
- 204, 204, 204, 204, 204, 204, 204, 204, 204, 204,
- 204, 204, 204, 204, 204, 204, 204, 204, 204, 204,
- 204, 204, 204, 204, 204, 204, 204, 204
+ 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
} ;
static yy_state_type yy_last_accepting_state;
@@ -702,7 +704,7 @@ static void countnl() {
g_lingo->_colnumber = strlen(p);
}
-#line 706 "engines/director/lingo/lingo-lex.cpp"
+#line 708 "engines/director/lingo/lingo-lex.cpp"
#define INITIAL 0
@@ -890,7 +892,7 @@ YY_DECL
#line 69 "engines/director/lingo/lingo-lex.l"
-#line 894 "engines/director/lingo/lingo-lex.cpp"
+#line 896 "engines/director/lingo/lingo-lex.cpp"
if ( !(yy_init) )
{
@@ -944,13 +946,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 >= 205 )
+ if ( yy_current_state >= 206 )
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] != 516 );
+ while ( yy_base[yy_current_state] != 521 );
yy_find_action:
yy_act = yy_accept[yy_current_state];
@@ -1099,66 +1101,71 @@ YY_RULE_SETUP
case 25:
YY_RULE_SETUP
#line 96 "engines/director/lingo/lingo-lex.l"
-{ count(); return tMOVIE; }
+{ count(); return tMOD; }
YY_BREAK
case 26:
YY_RULE_SETUP
#line 97 "engines/director/lingo/lingo-lex.l"
-{ count(); return tNEXT; }
+{ count(); return tMOVIE; }
YY_BREAK
case 27:
YY_RULE_SETUP
#line 98 "engines/director/lingo/lingo-lex.l"
-{ count(); return tNOT; }
+{ count(); return tNEXT; }
YY_BREAK
case 28:
YY_RULE_SETUP
#line 99 "engines/director/lingo/lingo-lex.l"
-{ count(); return tOF; }
+{ count(); return tNOT; }
YY_BREAK
case 29:
YY_RULE_SETUP
#line 100 "engines/director/lingo/lingo-lex.l"
-{ count(); return tOPEN; }
+{ count(); return tOF; }
YY_BREAK
case 30:
YY_RULE_SETUP
#line 101 "engines/director/lingo/lingo-lex.l"
-{ count(); return tOR; }
+{ count(); return tOPEN; }
YY_BREAK
case 31:
YY_RULE_SETUP
#line 102 "engines/director/lingo/lingo-lex.l"
-{ count(); return tPLAY; }
+{ count(); return tOR; }
YY_BREAK
case 32:
YY_RULE_SETUP
#line 103 "engines/director/lingo/lingo-lex.l"
-{ count(); return tPREVIOUS; }
+{ count(); return tPLAY; }
YY_BREAK
case 33:
YY_RULE_SETUP
#line 104 "engines/director/lingo/lingo-lex.l"
-{ count(); return tPUT; }
+{ count(); return tPREVIOUS; }
YY_BREAK
case 34:
YY_RULE_SETUP
#line 105 "engines/director/lingo/lingo-lex.l"
-{ count(); return tREPEAT; }
+{ count(); return tPUT; }
YY_BREAK
case 35:
YY_RULE_SETUP
#line 106 "engines/director/lingo/lingo-lex.l"
-{ count(); return tSET; }
+{ count(); return tREPEAT; }
YY_BREAK
case 36:
YY_RULE_SETUP
#line 107 "engines/director/lingo/lingo-lex.l"
-{ count(); return tSTARTS; }
+{ count(); return tSET; }
YY_BREAK
case 37:
YY_RULE_SETUP
#line 108 "engines/director/lingo/lingo-lex.l"
+{ count(); return tSTARTS; }
+ YY_BREAK
+case 38:
+YY_RULE_SETUP
+#line 109 "engines/director/lingo/lingo-lex.l"
{
count();
@@ -1168,9 +1175,9 @@ YY_RULE_SETUP
return THEENTITYWITHID;
}
YY_BREAK
-case 38:
+case 39:
YY_RULE_SETUP
-#line 116 "engines/director/lingo/lingo-lex.l"
+#line 117 "engines/director/lingo/lingo-lex.l"
{
count();
@@ -1212,9 +1219,9 @@ YY_RULE_SETUP
warning("Unhandled the entity %s", ptr);
}
YY_BREAK
-case 39:
+case 40:
YY_RULE_SETUP
-#line 156 "engines/director/lingo/lingo-lex.l"
+#line 157 "engines/director/lingo/lingo-lex.l"
{
count();
@@ -1235,64 +1242,64 @@ YY_RULE_SETUP
warning("Unhandled the entity %s", ptr);
}
YY_BREAK
-case 40:
-YY_RULE_SETUP
-#line 175 "engines/director/lingo/lingo-lex.l"
-{ count(); return tTHEN; }
- YY_BREAK
case 41:
YY_RULE_SETUP
#line 176 "engines/director/lingo/lingo-lex.l"
-{ count(); return tTO; }
+{ count(); return tTHEN; }
YY_BREAK
case 42:
YY_RULE_SETUP
#line 177 "engines/director/lingo/lingo-lex.l"
-{ count(); return tSPRITE; }
+{ count(); return tTO; }
YY_BREAK
case 43:
YY_RULE_SETUP
#line 178 "engines/director/lingo/lingo-lex.l"
-{ count(); return tWITH; }
+{ count(); return tSPRITE; }
YY_BREAK
case 44:
YY_RULE_SETUP
#line 179 "engines/director/lingo/lingo-lex.l"
-{ count(); return tWITHIN; }
+{ count(); return tWITH; }
YY_BREAK
case 45:
YY_RULE_SETUP
#line 180 "engines/director/lingo/lingo-lex.l"
-{ count(); return tWHEN; }
+{ count(); return tWITHIN; }
YY_BREAK
case 46:
YY_RULE_SETUP
#line 181 "engines/director/lingo/lingo-lex.l"
-{ count(); return tWHILE; }
+{ count(); return tWHEN; }
YY_BREAK
case 47:
YY_RULE_SETUP
-#line 183 "engines/director/lingo/lingo-lex.l"
-{ count(); return tNEQ; }
+#line 182 "engines/director/lingo/lingo-lex.l"
+{ count(); return tWHILE; }
YY_BREAK
case 48:
YY_RULE_SETUP
#line 184 "engines/director/lingo/lingo-lex.l"
-{ count(); return tGE; }
+{ count(); return tNEQ; }
YY_BREAK
case 49:
YY_RULE_SETUP
#line 185 "engines/director/lingo/lingo-lex.l"
-{ count(); return tLE; }
+{ count(); return tGE; }
YY_BREAK
case 50:
YY_RULE_SETUP
#line 186 "engines/director/lingo/lingo-lex.l"
-{ count(); return tCONCAT; }
+{ count(); return tLE; }
YY_BREAK
case 51:
YY_RULE_SETUP
-#line 188 "engines/director/lingo/lingo-lex.l"
+#line 187 "engines/director/lingo/lingo-lex.l"
+{ count(); return tCONCAT; }
+ YY_BREAK
+case 52:
+YY_RULE_SETUP
+#line 189 "engines/director/lingo/lingo-lex.l"
{
count();
yylval.s = new Common::String(yytext);
@@ -1320,43 +1327,43 @@ YY_RULE_SETUP
return ID;
}
YY_BREAK
-case 52:
-YY_RULE_SETUP
-#line 214 "engines/director/lingo/lingo-lex.l"
-{ count(); yylval.f = atof(yytext); return FLOAT; }
- YY_BREAK
case 53:
YY_RULE_SETUP
#line 215 "engines/director/lingo/lingo-lex.l"
-{ count(); yylval.i = strtol(yytext, NULL, 10); return INT; }
+{ count(); yylval.f = atof(yytext); return FLOAT; }
YY_BREAK
case 54:
YY_RULE_SETUP
#line 216 "engines/director/lingo/lingo-lex.l"
-{ count(); return *yytext; }
+{ count(); yylval.i = strtol(yytext, NULL, 10); return INT; }
YY_BREAK
case 55:
-/* rule 55 can match eol */
YY_RULE_SETUP
#line 217 "engines/director/lingo/lingo-lex.l"
-{ return '\n'; }
+{ count(); return *yytext; }
YY_BREAK
case 56:
+/* rule 56 can match eol */
YY_RULE_SETUP
#line 218 "engines/director/lingo/lingo-lex.l"
-{ count(); yylval.s = new Common::String(&yytext[1]); yylval.s->deleteLastChar(); return STRING; }
+{ return '\n'; }
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; }
YY_BREAK
case 58:
YY_RULE_SETUP
-#line 221 "engines/director/lingo/lingo-lex.l"
+#line 220 "engines/director/lingo/lingo-lex.l"
+
+ YY_BREAK
+case 59:
+YY_RULE_SETUP
+#line 222 "engines/director/lingo/lingo-lex.l"
ECHO;
YY_BREAK
-#line 1360 "engines/director/lingo/lingo-lex.cpp"
+#line 1367 "engines/director/lingo/lingo-lex.cpp"
case YY_STATE_EOF(INITIAL):
yyterminate();
@@ -1649,7 +1656,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 >= 205 )
+ if ( yy_current_state >= 206 )
yy_c = yy_meta[(unsigned int) yy_c];
}
yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
@@ -1677,11 +1684,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 >= 205 )
+ if ( yy_current_state >= 206 )
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 == 204);
+ yy_is_jam = (yy_current_state == 205);
return yy_is_jam ? 0 : yy_current_state;
}
@@ -2356,7 +2363,7 @@ void yyfree (void * ptr )
#define YYTABLES_NAME "yytables"
-#line 221 "engines/director/lingo/lingo-lex.l"
+#line 222 "engines/director/lingo/lingo-lex.l"
diff --git a/engines/director/lingo/lingo-lex.l b/engines/director/lingo/lingo-lex.l
index 571065df02..c2a5b19fb9 100644
--- a/engines/director/lingo/lingo-lex.l
+++ b/engines/director/lingo/lingo-lex.l
@@ -93,6 +93,7 @@ whitespace [\t ]
(?i:loop) { count(); return tLOOP; }
(?i:macro) { count(); return tMACRO; }
(?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; }
diff --git a/engines/director/lingo/lingo.h b/engines/director/lingo/lingo.h
index e04de92b8b..2cc1a09012 100644
--- a/engines/director/lingo/lingo.h
+++ b/engines/director/lingo/lingo.h
@@ -236,6 +236,7 @@ public:
static void c_sub();
static void c_mul();
static void c_div();
+ static void c_mod();
static void c_negate();
static void c_and();