diff options
-rw-r--r-- | engines/director/lingo/lingo-builtins.cpp | 8 | ||||
-rw-r--r-- | engines/director/lingo/lingo-code.cpp | 10 | ||||
-rw-r--r-- | engines/director/lingo/lingo-gr.cpp | 836 | ||||
-rw-r--r-- | engines/director/lingo/lingo-gr.h | 64 | ||||
-rw-r--r-- | engines/director/lingo/lingo-gr.y | 4 | ||||
-rw-r--r-- | engines/director/lingo/lingo-lex.cpp | 417 | ||||
-rw-r--r-- | engines/director/lingo/lingo-lex.l | 1 | ||||
-rw-r--r-- | engines/director/lingo/lingo.h | 3 | ||||
-rw-r--r-- | engines/director/lingo/tests/builtin.lingo | 4 |
9 files changed, 708 insertions, 639 deletions
diff --git a/engines/director/lingo/lingo-builtins.cpp b/engines/director/lingo/lingo-builtins.cpp index 06c3e7f7dd..58c1ef4460 100644 --- a/engines/director/lingo/lingo-builtins.cpp +++ b/engines/director/lingo/lingo-builtins.cpp @@ -58,6 +58,7 @@ static struct BuiltinProto { { "continue", Lingo::b_continue, 0, 0, false }, { "cursor", Lingo::b_cursor, 1, 1, false }, { "delay", Lingo::b_delay, 1, 1, false }, + { "do", Lingo::b_do, 1, 1, false }, { "dontPassEvent", Lingo::b_dontPassEvent, 0, 0, false }, { "editableText", Lingo::b_editableText, 0, 0, false }, { "installMenu", Lingo::b_installMenu, 1, 1, false }, @@ -330,6 +331,13 @@ void Lingo::b_moveableSprite() { warning("STUB: b_moveableSprite(%d)", d.u.i); } +void Lingo::b_do() { + Datum d = g_lingo->pop(); + d.toString(); + warning("STUB: b_do(%s)", d.u.s->c_str()); +} + + /////////////////// // Point diff --git a/engines/director/lingo/lingo-code.cpp b/engines/director/lingo/lingo-code.cpp index 021cdd1129..f9b2c1ccce 100644 --- a/engines/director/lingo/lingo-code.cpp +++ b/engines/director/lingo/lingo-code.cpp @@ -806,4 +806,14 @@ void Lingo::c_global() { g_lingo->_pc += g_lingo->calcStringAlignment(name.c_str()); } +void Lingo::c_open() { + Datum d2 = g_lingo->pop(); + Datum d1 = g_lingo->pop(); + + d1.toString(); + d2.toString(); + + warning("STUB: c_open(%s, %s)", d1.u.s->c_str(), d2.u.s->c_str()); +} + } diff --git a/engines/director/lingo/lingo-gr.cpp b/engines/director/lingo/lingo-gr.cpp index e309dc118a..87b231193a 100644 --- a/engines/director/lingo/lingo-gr.cpp +++ b/engines/director/lingo/lingo-gr.cpp @@ -114,21 +114,22 @@ tNLELSE = 303, tFACTORY = 304, tMETHOD = 305, - tGE = 306, - tLE = 307, - tGT = 308, - tLT = 309, - tEQ = 310, - tNEQ = 311, - tAND = 312, - tOR = 313, - tNOT = 314, - tCONCAT = 315, - tCONTAINS = 316, - tSTARTS = 317, - tSPRITE = 318, - tINTERSECTS = 319, - tWITHIN = 320 + tOPEN = 306, + tGE = 307, + tLE = 308, + tGT = 309, + tLT = 310, + tEQ = 311, + tNEQ = 312, + tAND = 313, + tOR = 314, + tNOT = 315, + tCONCAT = 316, + tCONTAINS = 317, + tSTARTS = 318, + tSPRITE = 319, + tINTERSECTS = 320, + tWITHIN = 321 }; #endif /* Tokens. */ @@ -180,21 +181,22 @@ #define tNLELSE 303 #define tFACTORY 304 #define tMETHOD 305 -#define tGE 306 -#define tLE 307 -#define tGT 308 -#define tLT 309 -#define tEQ 310 -#define tNEQ 311 -#define tAND 312 -#define tOR 313 -#define tNOT 314 -#define tCONCAT 315 -#define tCONTAINS 316 -#define tSTARTS 317 -#define tSPRITE 318 -#define tINTERSECTS 319 -#define tWITHIN 320 +#define tOPEN 306 +#define tGE 307 +#define tLE 308 +#define tGT 309 +#define tLT 310 +#define tEQ 311 +#define tNEQ 312 +#define tAND 313 +#define tOR 314 +#define tNOT 315 +#define tCONCAT 316 +#define tCONTAINS 317 +#define tSTARTS 318 +#define tSPRITE 319 +#define tINTERSECTS 320 +#define tWITHIN 321 @@ -252,7 +254,7 @@ typedef union YYSTYPE Common::Array<double> *arr; } /* Line 193 of yacc.c. */ -#line 256 "engines/director/lingo/lingo-gr.cpp" +#line 258 "engines/director/lingo/lingo-gr.cpp" YYSTYPE; # define yystype YYSTYPE /* obsolescent; will be withdrawn */ # define YYSTYPE_IS_DECLARED 1 @@ -265,7 +267,7 @@ typedef union YYSTYPE /* Line 216 of yacc.c. */ -#line 269 "engines/director/lingo/lingo-gr.cpp" +#line 271 "engines/director/lingo/lingo-gr.cpp" #ifdef short # undef short @@ -478,22 +480,22 @@ union yyalloc #endif /* YYFINAL -- State number of the termination state. */ -#define YYFINAL 81 +#define YYFINAL 83 /* YYLAST -- Last index in YYTABLE. */ -#define YYLAST 742 +#define YYLAST 800 /* YYNTOKENS -- Number of terminals. */ -#define YYNTOKENS 79 +#define YYNTOKENS 80 /* YYNNTS -- Number of nonterminals. */ #define YYNNTS 34 /* YYNRULES -- Number of rules. */ -#define YYNRULES 121 +#define YYNRULES 123 /* YYNRULES -- Number of states. */ -#define YYNSTATES 258 +#define YYNSTATES 262 /* YYTRANSLATE(YYLEX) -- Bison symbol number corresponding to YYLEX. */ #define YYUNDEFTOK 2 -#define YYMAXUTOK 320 +#define YYMAXUTOK 321 #define YYTRANSLATE(YYX) \ ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK) @@ -502,12 +504,12 @@ union yyalloc static const yytype_uint8 yytranslate[] = { 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 72, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 73, 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, 71, 77, 2, - 73, 74, 69, 67, 78, 68, 2, 70, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 72, 78, 2, + 74, 75, 70, 68, 79, 69, 2, 71, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, - 76, 66, 75, 2, 2, 2, 2, 2, 2, 2, + 77, 67, 76, 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, @@ -533,7 +535,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 + 65, 66 }; #if YYDEBUG @@ -550,61 +552,62 @@ static const yytype_uint16 yyprhs[] = 246, 248, 251, 253, 257, 261, 265, 269, 273, 277, 281, 285, 289, 293, 297, 300, 304, 308, 312, 316, 319, 322, 326, 331, 336, 339, 342, 345, 347, 349, - 352, 355, 358, 360, 362, 366, 369, 372, 375, 378, - 382, 385, 389, 392, 395, 397, 401, 404, 408, 409, - 418, 421, 422, 431, 432, 434, 438, 443, 444, 448, - 449, 451 + 352, 355, 358, 360, 365, 368, 370, 374, 377, 380, + 383, 386, 390, 393, 397, 400, 403, 405, 409, 412, + 416, 417, 426, 429, 430, 439, 440, 442, 446, 451, + 452, 456, 457, 459 }; /* YYRHS -- A `-1'-separated list of the rules' RHS. */ static const yytype_int8 yyrhs[] = { - 80, 0, -1, 80, 81, 82, -1, 82, -1, 1, - 72, -1, 72, -1, -1, 106, -1, 101, -1, 111, - -1, 83, -1, 85, -1, 40, 100, 31, 19, -1, - 42, 19, 66, 100, -1, 42, 12, 66, 100, -1, - 42, 13, 100, 66, 100, -1, 42, 19, 44, 100, - -1, 42, 12, 44, 100, -1, 42, 13, 100, 44, - 100, -1, 100, -1, 101, -1, 84, -1, 86, -1, - 93, 73, 92, 74, 99, 98, 25, 41, -1, 94, - 66, 100, 98, 44, 100, 98, 99, 98, 25, 41, - -1, 94, 66, 100, 98, 22, 44, 100, 98, 99, - 98, 25, 41, -1, 45, 19, 43, 100, -1, 95, - 92, 43, 81, 99, 98, 25, 30, -1, 95, 92, - 43, 81, 99, 98, 48, 99, 98, 25, 30, -1, - 95, 92, 43, 81, 99, 98, 97, 88, 98, 25, - 30, -1, 95, 92, 43, 97, 84, 98, -1, 95, - 92, 43, 97, 84, 98, 48, 97, 84, 98, -1, - 95, 92, 43, 97, 84, 98, 89, 98, 87, 98, - -1, -1, 48, 97, 84, -1, 88, 91, -1, 91, - -1, 89, 90, -1, 90, -1, 96, 92, 43, 97, - 85, 98, -1, 89, -1, 96, 92, 43, 99, 98, - -1, 100, -1, 100, 66, 100, -1, 73, 92, 74, + 81, 0, -1, 81, 82, 83, -1, 83, -1, 1, + 73, -1, 73, -1, -1, 107, -1, 102, -1, 112, + -1, 84, -1, 86, -1, 40, 101, 31, 19, -1, + 42, 19, 67, 101, -1, 42, 12, 67, 101, -1, + 42, 13, 101, 67, 101, -1, 42, 19, 44, 101, + -1, 42, 12, 44, 101, -1, 42, 13, 101, 44, + 101, -1, 101, -1, 102, -1, 85, -1, 87, -1, + 94, 74, 93, 75, 100, 99, 25, 41, -1, 95, + 67, 101, 99, 44, 101, 99, 100, 99, 25, 41, + -1, 95, 67, 101, 99, 22, 44, 101, 99, 100, + 99, 25, 41, -1, 45, 19, 43, 101, -1, 96, + 93, 43, 82, 100, 99, 25, 30, -1, 96, 93, + 43, 82, 100, 99, 48, 100, 99, 25, 30, -1, + 96, 93, 43, 82, 100, 99, 98, 89, 99, 25, + 30, -1, 96, 93, 43, 98, 85, 99, -1, 96, + 93, 43, 98, 85, 99, 48, 98, 85, 99, -1, + 96, 93, 43, 98, 85, 99, 90, 99, 88, 99, + -1, -1, 48, 98, 85, -1, 89, 92, -1, 92, + -1, 90, 91, -1, 91, -1, 97, 93, 43, 98, + 86, 99, -1, 90, -1, 97, 93, 43, 100, 99, + -1, 101, -1, 101, 67, 101, -1, 74, 93, 75, -1, 41, 47, -1, 41, 46, 19, -1, 30, -1, - 24, -1, -1, -1, -1, 99, 81, -1, 99, 85, + 24, -1, -1, -1, -1, 100, 82, -1, 100, 86, -1, 11, -1, 14, -1, 20, -1, 16, -1, 19, - 73, 112, 74, -1, 19, -1, 12, -1, 13, 100, - -1, 83, -1, 100, 67, 100, -1, 100, 68, 100, - -1, 100, 69, 100, -1, 100, 70, 100, -1, 100, - 75, 100, -1, 100, 76, 100, -1, 100, 56, 100, - -1, 100, 51, 100, -1, 100, 52, 100, -1, 100, - 57, 100, -1, 100, 58, 100, -1, 59, 100, -1, - 100, 77, 100, -1, 100, 60, 100, -1, 100, 61, - 100, -1, 100, 62, 100, -1, 67, 100, -1, 68, - 100, -1, 73, 100, 74, -1, 63, 100, 64, 100, - -1, 63, 100, 65, 100, -1, 34, 20, -1, 35, - 19, -1, 40, 100, -1, 103, -1, 26, -1, 28, - 102, -1, 18, 100, -1, 17, 100, -1, 17, -1, - 19, -1, 102, 78, 19, -1, 29, 32, -1, 29, - 37, -1, 29, 39, -1, 29, 104, -1, 29, 104, - 105, -1, 29, 105, -1, 44, 27, 20, -1, 27, - 20, -1, 44, 20, -1, 20, -1, 38, 36, 20, - -1, 36, 20, -1, 44, 36, 20, -1, -1, 33, - 19, 107, 97, 109, 81, 110, 99, -1, 49, 19, - -1, -1, 50, 19, 108, 97, 109, 81, 110, 99, - -1, -1, 19, -1, 109, 78, 19, -1, 109, 81, - 78, 19, -1, -1, 19, 97, 112, -1, -1, 100, - -1, 112, 78, 100, -1 + 74, 113, 75, -1, 19, -1, 12, -1, 13, 101, + -1, 84, -1, 101, 68, 101, -1, 101, 69, 101, + -1, 101, 70, 101, -1, 101, 71, 101, -1, 101, + 76, 101, -1, 101, 77, 101, -1, 101, 57, 101, + -1, 101, 52, 101, -1, 101, 53, 101, -1, 101, + 58, 101, -1, 101, 59, 101, -1, 60, 101, -1, + 101, 78, 101, -1, 101, 61, 101, -1, 101, 62, + 101, -1, 101, 63, 101, -1, 68, 101, -1, 69, + 101, -1, 74, 101, 75, -1, 64, 101, 65, 101, + -1, 64, 101, 66, 101, -1, 34, 20, -1, 35, + 19, -1, 40, 101, -1, 104, -1, 26, -1, 28, + 103, -1, 18, 101, -1, 17, 101, -1, 17, -1, + 51, 101, 46, 101, -1, 51, 101, -1, 19, -1, + 103, 79, 19, -1, 29, 32, -1, 29, 37, -1, + 29, 39, -1, 29, 105, -1, 29, 105, 106, -1, + 29, 106, -1, 44, 27, 20, -1, 27, 20, -1, + 44, 20, -1, 20, -1, 38, 36, 20, -1, 36, + 20, -1, 44, 36, 20, -1, -1, 33, 19, 108, + 98, 110, 82, 111, 100, -1, 49, 19, -1, -1, + 50, 19, 109, 98, 110, 82, 111, 100, -1, -1, + 19, -1, 110, 79, 19, -1, 110, 82, 79, 19, + -1, -1, 19, 98, 113, -1, -1, 101, -1, 113, + 79, 101, -1 }; /* YYRLINE[YYN] -- source line where rule number YYN was defined. */ @@ -619,10 +622,10 @@ static const yytype_uint16 yyrline[] = 362, 369, 375, 376, 377, 378, 379, 380, 381, 382, 383, 384, 385, 386, 387, 388, 389, 390, 391, 392, 393, 394, 395, 396, 399, 400, 401, 402, 403, 405, - 406, 409, 412, 417, 418, 429, 430, 431, 432, 437, - 443, 450, 451, 452, 453, 456, 457, 458, 486, 486, - 492, 495, 495, 501, 502, 503, 504, 506, 510, 518, - 519, 520 + 406, 409, 412, 415, 416, 419, 420, 431, 432, 433, + 434, 439, 445, 452, 453, 454, 455, 458, 459, 460, + 488, 488, 494, 497, 497, 503, 504, 505, 506, 508, + 512, 520, 521, 522 }; #endif @@ -638,8 +641,8 @@ static const char *const yytname[] = "tEND", "tEXIT", "tFRAME", "tGLOBAL", "tGO", "tIF", "tINTO", "tLOOP", "tMACRO", "tMCI", "tMCIWAIT", "tMOVIE", "tNEXT", "tOF", "tPREVIOUS", "tPUT", "tREPEAT", "tSET", "tTHEN", "tTO", "tWHEN", "tWITH", "tWHILE", - "tNLELSE", "tFACTORY", "tMETHOD", "tGE", "tLE", "tGT", "tLT", "tEQ", - "tNEQ", "tAND", "tOR", "tNOT", "tCONCAT", "tCONTAINS", "tSTARTS", + "tNLELSE", "tFACTORY", "tMETHOD", "tOPEN", "tGE", "tLE", "tGT", "tLT", + "tEQ", "tNEQ", "tAND", "tOR", "tNOT", "tCONCAT", "tCONTAINS", "tSTARTS", "tSPRITE", "tINTERSECTS", "tWITHIN", "'='", "'+'", "'-'", "'*'", "'/'", "'%'", "'\\n'", "'('", "')'", "'>'", "'<'", "'&'", "','", "$accept", "program", "nl", "programline", "asgn", "stmtoneliner", "stmt", "ifstmt", @@ -662,27 +665,27 @@ static const yytype_uint16 yytoknum[] = 285, 286, 287, 288, 289, 290, 291, 292, 293, 294, 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, 61, 43, 45, 42, - 47, 37, 10, 40, 41, 62, 60, 38, 44 + 315, 316, 317, 318, 319, 320, 321, 61, 43, 45, + 42, 47, 37, 10, 40, 41, 62, 60, 38, 44 }; # endif /* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */ static const yytype_uint8 yyr1[] = { - 0, 79, 80, 80, 80, 81, 82, 82, 82, 82, - 82, 82, 83, 83, 83, 83, 83, 83, 83, 84, - 84, 85, 85, 85, 85, 85, 85, 86, 86, 86, - 86, 86, 86, 87, 87, 88, 88, 89, 89, 90, - 91, 91, 92, 92, 92, 93, 94, 95, 96, 97, - 98, 99, 99, 99, 100, 100, 100, 100, 100, 100, - 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, - 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, - 100, 100, 100, 100, 101, 101, 101, 101, 101, 101, - 101, 101, 101, 102, 102, 103, 103, 103, 103, 103, - 103, 104, 104, 104, 104, 105, 105, 105, 107, 106, - 106, 108, 106, 109, 109, 109, 109, 110, 111, 112, - 112, 112 + 0, 80, 81, 81, 81, 82, 83, 83, 83, 83, + 83, 83, 84, 84, 84, 84, 84, 84, 84, 85, + 85, 86, 86, 86, 86, 86, 86, 87, 87, 87, + 87, 87, 87, 88, 88, 89, 89, 90, 90, 91, + 92, 92, 93, 93, 93, 94, 95, 96, 97, 98, + 99, 100, 100, 100, 101, 101, 101, 101, 101, 101, + 101, 101, 101, 101, 101, 101, 101, 101, 101, 101, + 101, 101, 101, 101, 101, 101, 101, 101, 101, 101, + 101, 101, 101, 101, 102, 102, 102, 102, 102, 102, + 102, 102, 102, 102, 102, 103, 103, 104, 104, 104, + 104, 104, 104, 105, 105, 105, 105, 106, 106, 106, + 108, 107, 107, 109, 107, 110, 110, 110, 110, 111, + 112, 113, 113, 113 }; /* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN. */ @@ -697,10 +700,10 @@ static const yytype_uint8 yyr2[] = 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, 2, 2, 1, 1, 2, - 2, 2, 1, 1, 3, 2, 2, 2, 2, 3, - 2, 3, 2, 2, 1, 3, 2, 3, 0, 8, - 2, 0, 8, 0, 1, 3, 4, 0, 3, 0, - 1, 3 + 2, 2, 1, 4, 2, 1, 3, 2, 2, 2, + 2, 3, 2, 3, 2, 2, 1, 3, 2, 3, + 0, 8, 2, 0, 8, 0, 1, 3, 4, 0, + 3, 0, 1, 3 }; /* YYDEFACT[STATE-NAME] -- Default rule to reduce with in state @@ -711,38 +714,39 @@ static const yytype_uint8 yydefact[] = 0, 0, 54, 60, 0, 55, 57, 92, 0, 49, 56, 88, 0, 0, 47, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 3, 62, 21, 11, 22, 0, 0, 0, 19, 8, - 87, 7, 9, 4, 59, 0, 62, 61, 91, 90, - 119, 119, 93, 89, 104, 0, 95, 0, 96, 0, - 97, 0, 98, 100, 108, 84, 85, 86, 0, 45, - 0, 0, 0, 0, 110, 111, 74, 0, 79, 80, - 0, 1, 5, 6, 0, 0, 0, 0, 42, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 120, 0, 118, 0, 102, - 106, 0, 103, 0, 0, 0, 99, 49, 0, 46, - 0, 0, 0, 0, 0, 0, 49, 0, 0, 81, - 2, 0, 50, 0, 0, 49, 0, 70, 71, 69, - 72, 73, 76, 77, 78, 63, 64, 65, 66, 67, - 68, 75, 58, 0, 94, 105, 101, 107, 113, 12, - 17, 14, 0, 0, 16, 13, 26, 113, 82, 83, - 51, 0, 44, 51, 0, 43, 121, 114, 0, 18, - 15, 0, 50, 0, 0, 50, 50, 20, 0, 117, - 117, 52, 53, 0, 0, 50, 49, 30, 115, 0, - 51, 51, 0, 50, 51, 0, 51, 0, 48, 49, - 50, 38, 0, 116, 109, 112, 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, 3, 62, 21, 11, 22, 0, 0, 0, 19, + 8, 87, 7, 9, 4, 59, 0, 62, 61, 91, + 90, 121, 121, 95, 89, 106, 0, 97, 0, 98, + 0, 99, 0, 100, 102, 110, 84, 85, 86, 0, + 45, 0, 0, 0, 0, 112, 113, 94, 74, 0, + 79, 80, 0, 1, 5, 6, 0, 0, 0, 0, + 42, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 122, 0, 120, + 0, 104, 108, 0, 105, 0, 0, 0, 101, 49, + 0, 46, 0, 0, 0, 0, 0, 0, 49, 0, + 0, 0, 81, 2, 0, 50, 0, 0, 49, 0, + 70, 71, 69, 72, 73, 76, 77, 78, 63, 64, + 65, 66, 67, 68, 75, 58, 0, 96, 107, 103, + 109, 115, 12, 17, 14, 0, 0, 16, 13, 26, + 115, 93, 82, 83, 51, 0, 44, 51, 0, 43, + 123, 116, 0, 18, 15, 0, 50, 0, 0, 50, + 50, 20, 0, 119, 119, 52, 53, 0, 0, 50, + 49, 30, 117, 0, 51, 51, 0, 50, 51, 0, + 51, 0, 48, 49, 50, 38, 0, 118, 111, 114, + 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, 29, 191, 30, 46, 32, 192, 34, 237, 221, - 222, 211, 223, 87, 35, 36, 37, 212, 247, 171, - 182, 38, 187, 53, 40, 62, 63, 41, 117, 126, - 178, 200, 42, 106 + -1, 30, 195, 31, 47, 33, 196, 35, 241, 225, + 226, 215, 227, 89, 36, 37, 38, 216, 251, 175, + 186, 39, 191, 54, 41, 63, 64, 42, 119, 128, + 182, 204, 43, 108 }; /* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing @@ -750,41 +754,42 @@ static const yytype_int16 yydefgoto[] = #define YYPACT_NINF -180 static const yytype_int16 yypact[] = { - 203, -51, -180, -180, 428, -180, -180, 428, 428, 638, - -180, -180, 4, 219, -180, 15, 12, 35, 428, 13, - 36, 38, 46, 49, 428, 428, 428, 428, 428, 2, - -180, 3, -180, -180, -180, -32, 5, 460, 616, -180, - -180, -180, -180, -180, 8, 428, -180, 616, 616, 616, - 428, 428, -180, -5, -180, 50, -180, 56, -180, 41, - -180, -3, 9, -180, -180, -180, -180, 474, 60, -180, - -29, 428, -26, 39, -180, -180, 270, 518, 270, 270, - 567, -180, -180, 266, 460, 428, 460, 45, 594, 428, - 428, 428, 428, 428, 428, 428, 428, 428, 428, 428, - 428, 428, 428, 428, 474, 616, -12, 29, 65, -180, - -180, 88, -180, 91, 92, 77, -180, -180, 95, -180, - 428, 428, 496, 428, 428, 428, -180, 428, 428, -180, - -180, 42, 616, 43, 540, 47, 428, 616, 616, 616, - 616, 616, 616, 616, 616, 665, 665, 270, 270, 616, - 616, 616, -180, 428, -180, -180, -180, -180, 96, -180, - 616, 616, 428, 428, 616, 616, 616, 96, 616, 616, - -180, -2, -180, -180, 396, 616, 616, -180, -22, 616, - 616, -22, 324, 76, 428, 324, -180, -180, 104, 52, - 52, -180, -180, 106, 428, 616, -9, -13, -180, 113, - -180, -180, 93, 616, -180, 103, -180, 111, -180, -180, - 111, -180, 460, -180, 324, 324, -180, -180, 324, -180, - 324, 111, 111, -180, 460, 396, -180, 97, 98, 324, - 115, 119, -180, 121, 105, -180, -180, -180, -180, 122, - 108, 125, 127, -11, -180, 396, -180, 360, 110, -180, - -180, -180, 324, -180, -180, -180, -180, -180 + 208, -57, -180, -180, 479, -180, -180, 479, 479, 695, + -180, -180, 30, 31, -180, 33, 27, 38, 479, -11, + 131, 41, 46, 52, 479, 479, 479, 479, 479, 479, + 3, -180, 4, -180, -180, -180, 6, 15, 490, 673, + -180, -180, -180, -180, -180, 9, 479, -180, 673, 673, + 673, 479, 479, -180, -6, -180, 66, -180, 67, -180, + 55, -180, -2, 28, -180, -180, -180, -180, 504, 73, + -180, -30, 479, -22, 71, -180, -180, 553, 60, 575, + 60, 60, 624, -180, -180, 272, 490, 479, 490, 72, + 651, 479, 479, 479, 479, 479, 479, 479, 479, 479, + 479, 479, 479, 479, 479, 479, 504, 673, -60, 37, + 107, -180, -180, 114, -180, 119, 120, 112, -180, -180, + 130, -180, 479, 479, 526, 479, 479, 479, -180, 479, + 479, 479, -180, -180, 76, 673, 77, 597, 80, 479, + 673, 673, 673, 673, 673, 673, 673, 673, 722, 722, + 60, 60, 673, 673, 673, -180, 479, -180, -180, -180, + -180, 137, -180, 673, 673, 479, 479, 673, 673, 673, + 137, 673, 673, 673, -180, -1, -180, -180, 454, 673, + 673, -180, 5, 673, 673, 5, 331, 115, 479, 331, + -180, -180, 141, 82, 82, -180, -180, 139, 479, 673, + 8, -7, -180, 143, -180, -180, 124, 673, -180, 136, + -180, 145, -180, -180, 145, -180, 490, -180, 331, 331, + -180, -180, 331, -180, 331, 145, 145, -180, 490, 454, + -180, 123, 129, 331, 148, 149, -180, 150, 133, -180, + -180, -180, -180, 152, 138, 153, 154, -12, -180, 454, + -180, 395, 144, -180, -180, -180, 331, -180, -180, -180, + -180, -180 }; /* YYPGOTO[NTERM-NUM]. */ static const yytype_int16 yypgoto[] = { - -180, -180, -25, 53, 6, -167, 0, -180, -180, -180, - -39, -179, -62, -74, -180, -180, -180, -177, -8, -43, - -137, 1, 22, -180, -180, -180, 99, -180, -180, -180, - -1, -28, -180, 114 + -180, -180, -28, 97, 23, -170, 0, -180, -180, -180, + -15, -164, -38, -81, -180, -180, -180, -179, -8, -44, + -166, 2, 24, -180, -180, -180, 125, -180, -180, -180, + 21, 7, -180, 142 }; /* YYTABLE[YYPACT[STATE-NUM]]. What to do in state STATE-NUM. If @@ -794,160 +799,172 @@ static const yytype_int16 yypgoto[] = #define YYTABLE_NINF -60 static const yytype_int16 yytable[] = { - 33, 51, 81, -10, 83, 47, 31, 186, 48, 49, - 131, 208, 133, -51, -51, 120, 205, 112, 123, 67, - 183, 43, 39, 52, 113, 76, 77, 78, 79, 80, - 224, 226, 65, 114, 64, 209, 185, 121, 88, 206, - 124, 84, 184, 226, 224, 57, 104, 59, 70, 71, - 82, 105, 105, 115, 66, 72, 188, 73, 235, 68, - 69, -51, 152, 214, 215, 74, 153, 218, 75, 220, - 109, 85, 122, 108, 82, -10, 110, 111, 253, 119, - 229, 50, 125, 33, 154, 88, 132, 134, 135, 31, - 137, 138, 139, 140, 141, 142, 143, 144, 145, 146, - 147, 148, 149, 150, 151, 39, 252, 153, 155, 158, - 173, 156, 157, 114, 159, 177, 170, 172, 167, 82, - 194, 160, 161, 198, 164, 165, 166, 174, 168, 169, - 199, 202, 213, 219, 216, 208, 130, 175, 228, 193, - 240, 238, 196, 197, 241, 236, 242, 248, 243, 249, - 234, 255, 204, 189, 176, 250, 190, 251, 210, 232, - 217, 116, 201, 179, 180, 107, 181, 227, 0, 0, - 0, 0, 0, 0, 0, 230, 0, 231, 233, 0, - 0, 0, 0, 0, 0, 195, 239, 0, 207, 0, - 0, 0, 244, 0, 246, 203, 0, 0, 0, 0, - 0, 225, 0, -6, 1, 0, 0, 0, 0, 256, - 0, 257, 0, 88, 2, 3, 4, 5, 0, 6, - 7, 8, 9, 10, 0, 88, 0, 0, 245, 11, - 0, 12, 13, 14, 0, 0, 15, 16, 17, 54, - 0, 0, 0, 18, 19, 20, 55, 254, 21, 0, - 0, 56, 22, 23, 0, 57, 58, 59, 60, 0, - 0, 0, 24, 61, 0, 0, 25, 0, 0, 0, - 26, 27, 0, 0, 0, -6, 28, 2, 3, 4, - 5, 0, 6, 7, 8, 9, 10, 0, 0, 0, - 0, 0, 11, 0, 12, 13, 14, 0, 0, 15, - 16, 17, 0, 0, 0, 0, 18, 19, 20, 0, - 0, 21, 0, 0, 0, 22, 23, 0, 0, 0, - 0, 89, 90, 0, 0, 24, 91, 92, 93, 25, - 94, 95, 96, 26, 27, 2, 3, 4, 5, 28, - 6, 7, 8, 44, 10, 101, 102, 103, 0, 0, - 11, 0, 12, 13, 14, 0, 0, 0, 16, 17, - 0, 0, 0, 0, 18, 19, 20, 0, 0, 21, - 0, 2, 3, 4, 5, 0, 6, 7, 8, 44, - 10, 0, 0, 24, 0, 0, 11, 25, 12, 13, - 14, 26, 27, 0, 16, 17, 82, 28, 0, 0, - 18, 19, 20, 0, 0, 21, 0, 2, 3, 4, - 5, 0, 6, 7, 8, 44, 10, 0, 0, 24, - 0, 0, 11, 25, 12, 13, 0, 26, 27, 0, - 16, 17, 0, 28, 0, 0, 18, 0, 20, 2, - 3, 4, 5, 0, 6, 0, 0, 44, 10, 0, - 0, 0, 0, 0, 0, 24, 0, 0, 0, 25, - 0, 0, 0, 26, 27, 0, 0, 0, 45, 28, - 20, 2, 3, 4, 5, 0, 6, 0, 0, 44, - 10, 0, 0, 0, 0, 0, 0, 24, 0, 0, - 0, 25, 0, 0, 0, 26, 27, 0, 0, 0, - 45, 28, 20, 0, 0, 118, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 24, - 0, 0, 0, 25, 0, 89, 90, 26, 27, 0, - 91, 92, 93, 86, 94, 95, 96, 0, 0, 0, - 162, 97, 98, 99, 100, 0, 0, 89, 90, 101, - 102, 103, 91, 92, 93, 0, 94, 95, 96, 0, - 0, 0, 163, 97, 98, 99, 100, 0, 0, 89, - 90, 101, 102, 103, 91, 92, 93, 0, 94, 95, - 96, 0, 127, 128, 0, 97, 98, 99, 100, 0, - 0, 89, 90, 101, 102, 103, 91, 92, 93, 0, - 94, 95, 96, 0, 0, 0, 136, 97, 98, 99, - 100, 0, 0, 0, 129, 101, 102, 103, 89, 90, - 0, 0, 0, 91, 92, 93, 0, 94, 95, 96, - 0, 0, 0, 0, 97, 98, 99, 100, 0, 0, - 0, 129, 101, 102, 103, 89, 90, 0, 0, 0, - 91, 92, 93, 0, 94, 95, 96, 0, 0, 0, - 136, 97, 98, 99, 100, 0, 0, 89, 90, 101, - 102, 103, 91, 92, 93, 0, 94, 95, 96, 0, - 0, 0, 0, 97, 98, 99, 100, 0, 0, -59, - -59, 101, 102, 103, -59, -59, -59, 0, -59, -59, - -59, 0, 0, 0, 0, 0, 0, -59, -59, 0, - 0, 50, 0, -59, -59, -59, 89, 90, 0, 0, - 0, 91, 92, 93, 0, 94, 95, 96, 0, 0, - 0, 0, 0, 0, 99, 100, 0, 0, 0, 0, - 101, 102, 103 + 34, 52, 85, 83, -10, 134, 48, 136, 190, 49, + 50, 189, -51, -51, 122, 155, 44, 212, 114, 156, + 68, 187, 125, 32, 40, 115, 77, 78, 79, 80, + 81, 82, 228, 209, 116, 69, 70, 123, 218, 219, + 90, 213, 222, 188, 224, 126, 228, 66, 106, 53, + 230, 55, 65, 107, 107, 233, 210, 67, 56, 239, + 74, -51, 230, 57, 58, 75, 60, 58, 59, 60, + 61, 76, 117, 110, 124, 62, 84, -10, 84, 257, + 86, 256, 87, 51, 192, 34, 111, 112, 90, 135, + 137, 113, 121, 140, 141, 142, 143, 144, 145, 146, + 147, 148, 149, 150, 151, 152, 153, 154, 32, 40, + 177, 161, 91, 92, 127, 138, 156, 93, 94, 95, + 170, 96, 97, 98, 163, 164, 157, 167, 168, 169, + 178, 171, 172, 173, 158, 232, 103, 104, 105, 159, + 160, 179, 197, 71, 72, 200, 201, 238, 116, 162, + 73, 174, 176, 84, 193, 208, 181, 194, 180, 198, + 202, 203, 217, 221, 206, 220, 223, 183, 184, 212, + 231, 240, 242, 244, 245, 246, 247, 252, 234, 253, + 235, 237, 133, 254, 255, 259, 214, 236, 118, 243, + 199, 185, 211, 0, 109, 248, 0, 250, 0, 0, + 207, 205, 0, 0, 0, 229, 0, 0, -6, 1, + 0, 0, 260, 0, 261, 0, 0, 0, 90, 2, + 3, 4, 5, 0, 6, 7, 8, 9, 10, 0, + 90, 0, 249, 0, 11, 0, 12, 13, 14, 0, + 0, 15, 16, 17, 0, 0, 0, 0, 18, 19, + 20, 258, 0, 21, 0, 0, 0, 22, 23, 24, + 0, 0, 0, 0, 0, 0, 0, 0, 25, 0, + 0, 0, 26, 0, 0, 0, 27, 28, 0, 0, + 0, -6, 29, 2, 3, 4, 5, 0, 6, 7, + 8, 9, 10, 0, 0, 0, 0, 0, 11, 0, + 12, 13, 14, 0, 0, 15, 16, 17, 0, 0, + 0, 0, 18, 19, 20, 0, 0, 21, 0, 0, + 0, 22, 23, 24, 0, 0, 0, 0, 0, 0, + 0, 0, 25, 0, 0, 0, 26, 0, 0, 0, + 27, 28, 2, 3, 4, 5, 29, 6, 7, 8, + 45, 10, 0, 0, 0, 0, 0, 11, 0, 12, + 13, 14, 0, 0, 0, 16, 17, 0, 0, 0, + 0, 18, 19, 20, 0, 0, 21, 0, 0, 0, + 0, 0, 24, 0, 0, 0, 0, 0, 0, 0, + 0, 25, 0, 0, 0, 26, 0, 0, 0, 27, + 28, 0, 0, 0, 84, 29, 2, 3, 4, 5, + 0, 6, 7, 8, 45, 10, 0, 0, 0, 0, + 0, 11, 0, 12, 13, 14, 0, 0, 0, 16, + 17, 0, 0, 0, 0, 18, 19, 20, 0, 0, + 21, 0, 0, 0, 0, 0, 24, 0, 0, 0, + 0, 0, 0, 0, 0, 25, 0, 0, 0, 26, + 0, 0, 0, 27, 28, 2, 3, 4, 5, 29, + 6, 7, 8, 45, 10, 0, 0, 0, 0, 0, + 11, 0, 12, 13, 0, 0, 0, 0, 16, 17, + 2, 3, 4, 5, 18, 6, 20, 0, 45, 10, + 0, 2, 3, 4, 5, 24, 6, 0, 0, 45, + 10, 0, 0, 0, 25, 0, 0, 0, 26, 46, + 0, 20, 27, 28, 0, 0, 0, 0, 29, 0, + 46, 0, 20, 0, 0, 120, 0, 0, 0, 25, + 0, 0, 0, 26, 0, 0, 0, 27, 28, 0, + 25, 0, 0, 29, 26, 0, 91, 92, 27, 28, + 0, 93, 94, 95, 88, 96, 97, 98, 0, 0, + 165, 0, 99, 100, 101, 102, 0, 0, 91, 92, + 103, 104, 105, 93, 94, 95, 0, 96, 97, 98, + 0, 0, 0, 166, 99, 100, 101, 102, 0, 129, + 0, 0, 103, 104, 105, 91, 92, 0, 0, 0, + 93, 94, 95, 0, 96, 97, 98, 0, 0, 0, + 0, 99, 100, 101, 102, 0, 0, 91, 92, 103, + 104, 105, 93, 94, 95, 0, 96, 97, 98, 0, + 130, 131, 0, 99, 100, 101, 102, 0, 0, 91, + 92, 103, 104, 105, 93, 94, 95, 0, 96, 97, + 98, 0, 0, 0, 139, 99, 100, 101, 102, 0, + 0, 0, 132, 103, 104, 105, 91, 92, 0, 0, + 0, 93, 94, 95, 0, 96, 97, 98, 0, 0, + 0, 0, 99, 100, 101, 102, 0, 0, 0, 132, + 103, 104, 105, 91, 92, 0, 0, 0, 93, 94, + 95, 0, 96, 97, 98, 0, 0, 0, 139, 99, + 100, 101, 102, 0, 0, 91, 92, 103, 104, 105, + 93, 94, 95, 0, 96, 97, 98, 0, 0, 0, + 0, 99, 100, 101, 102, 0, 0, -59, -59, 103, + 104, 105, -59, -59, -59, 0, -59, -59, -59, 0, + 0, 0, 0, 0, 0, -59, -59, 0, 0, 51, + 0, -59, -59, -59, 91, 92, 0, 0, 0, 93, + 94, 95, 0, 96, 97, 98, 0, 0, 0, 0, + 0, 0, 101, 102, 0, 0, 0, 0, 103, 104, + 105 }; static const yytype_int16 yycheck[] = { - 0, 9, 0, 0, 29, 4, 0, 174, 7, 8, - 84, 24, 86, 24, 25, 44, 25, 20, 44, 18, - 22, 72, 0, 19, 27, 24, 25, 26, 27, 28, - 207, 210, 20, 36, 19, 48, 173, 66, 37, 48, - 66, 73, 44, 222, 221, 36, 45, 38, 12, 13, - 72, 50, 51, 44, 19, 19, 78, 19, 225, 46, - 47, 72, 74, 200, 201, 19, 78, 204, 19, 206, - 20, 66, 71, 78, 72, 72, 20, 36, 245, 19, - 217, 73, 43, 83, 19, 84, 85, 86, 43, 83, - 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, - 99, 100, 101, 102, 103, 83, 243, 78, 20, 117, - 135, 20, 20, 36, 19, 19, 74, 74, 126, 72, - 44, 120, 121, 19, 123, 124, 125, 135, 127, 128, - 78, 25, 19, 30, 41, 24, 83, 136, 212, 182, - 25, 43, 185, 186, 25, 48, 25, 25, 43, 41, - 224, 41, 195, 178, 153, 30, 181, 30, 197, 221, - 203, 62, 190, 162, 163, 51, 167, 210, -1, -1, - -1, -1, -1, -1, -1, 218, -1, 220, 221, -1, - -1, -1, -1, -1, -1, 184, 229, -1, 196, -1, - -1, -1, 235, -1, 237, 194, -1, -1, -1, -1, - -1, 209, -1, 0, 1, -1, -1, -1, -1, 252, - -1, 254, -1, 212, 11, 12, 13, 14, -1, 16, - 17, 18, 19, 20, -1, 224, -1, -1, 236, 26, - -1, 28, 29, 30, -1, -1, 33, 34, 35, 20, - -1, -1, -1, 40, 41, 42, 27, 247, 45, -1, - -1, 32, 49, 50, -1, 36, 37, 38, 39, -1, - -1, -1, 59, 44, -1, -1, 63, -1, -1, -1, - 67, 68, -1, -1, -1, 72, 73, 11, 12, 13, - 14, -1, 16, 17, 18, 19, 20, -1, -1, -1, - -1, -1, 26, -1, 28, 29, 30, -1, -1, 33, - 34, 35, -1, -1, -1, -1, 40, 41, 42, -1, - -1, 45, -1, -1, -1, 49, 50, -1, -1, -1, - -1, 51, 52, -1, -1, 59, 56, 57, 58, 63, - 60, 61, 62, 67, 68, 11, 12, 13, 14, 73, - 16, 17, 18, 19, 20, 75, 76, 77, -1, -1, - 26, -1, 28, 29, 30, -1, -1, -1, 34, 35, - -1, -1, -1, -1, 40, 41, 42, -1, -1, 45, - -1, 11, 12, 13, 14, -1, 16, 17, 18, 19, - 20, -1, -1, 59, -1, -1, 26, 63, 28, 29, - 30, 67, 68, -1, 34, 35, 72, 73, -1, -1, - 40, 41, 42, -1, -1, 45, -1, 11, 12, 13, - 14, -1, 16, 17, 18, 19, 20, -1, -1, 59, - -1, -1, 26, 63, 28, 29, -1, 67, 68, -1, - 34, 35, -1, 73, -1, -1, 40, -1, 42, 11, - 12, 13, 14, -1, 16, -1, -1, 19, 20, -1, - -1, -1, -1, -1, -1, 59, -1, -1, -1, 63, - -1, -1, -1, 67, 68, -1, -1, -1, 40, 73, - 42, 11, 12, 13, 14, -1, 16, -1, -1, 19, - 20, -1, -1, -1, -1, -1, -1, 59, -1, -1, - -1, 63, -1, -1, -1, 67, 68, -1, -1, -1, - 40, 73, 42, -1, -1, 31, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, 59, - -1, -1, -1, 63, -1, 51, 52, 67, 68, -1, - 56, 57, 58, 73, 60, 61, 62, -1, -1, -1, - 44, 67, 68, 69, 70, -1, -1, 51, 52, 75, - 76, 77, 56, 57, 58, -1, 60, 61, 62, -1, - -1, -1, 66, 67, 68, 69, 70, -1, -1, 51, - 52, 75, 76, 77, 56, 57, 58, -1, 60, 61, - 62, -1, 64, 65, -1, 67, 68, 69, 70, -1, - -1, 51, 52, 75, 76, 77, 56, 57, 58, -1, - 60, 61, 62, -1, -1, -1, 66, 67, 68, 69, - 70, -1, -1, -1, 74, 75, 76, 77, 51, 52, - -1, -1, -1, 56, 57, 58, -1, 60, 61, 62, - -1, -1, -1, -1, 67, 68, 69, 70, -1, -1, - -1, 74, 75, 76, 77, 51, 52, -1, -1, -1, - 56, 57, 58, -1, 60, 61, 62, -1, -1, -1, - 66, 67, 68, 69, 70, -1, -1, 51, 52, 75, - 76, 77, 56, 57, 58, -1, 60, 61, 62, -1, - -1, -1, -1, 67, 68, 69, 70, -1, -1, 51, - 52, 75, 76, 77, 56, 57, 58, -1, 60, 61, - 62, -1, -1, -1, -1, -1, -1, 69, 70, -1, - -1, 73, -1, 75, 76, 77, 51, 52, -1, -1, - -1, 56, 57, 58, -1, 60, 61, 62, -1, -1, - -1, -1, -1, -1, 69, 70, -1, -1, -1, -1, - 75, 76, 77 + 0, 9, 30, 0, 0, 86, 4, 88, 178, 7, + 8, 177, 24, 25, 44, 75, 73, 24, 20, 79, + 18, 22, 44, 0, 0, 27, 24, 25, 26, 27, + 28, 29, 211, 25, 36, 46, 47, 67, 204, 205, + 38, 48, 208, 44, 210, 67, 225, 20, 46, 19, + 214, 20, 19, 51, 52, 221, 48, 19, 27, 229, + 19, 73, 226, 32, 36, 19, 38, 36, 37, 38, + 39, 19, 44, 79, 72, 44, 73, 73, 73, 249, + 74, 247, 67, 74, 79, 85, 20, 20, 86, 87, + 88, 36, 19, 91, 92, 93, 94, 95, 96, 97, + 98, 99, 100, 101, 102, 103, 104, 105, 85, 85, + 138, 119, 52, 53, 43, 43, 79, 57, 58, 59, + 128, 61, 62, 63, 122, 123, 19, 125, 126, 127, + 138, 129, 130, 131, 20, 216, 76, 77, 78, 20, + 20, 139, 186, 12, 13, 189, 190, 228, 36, 19, + 19, 75, 75, 73, 182, 199, 19, 185, 156, 44, + 19, 79, 19, 207, 25, 41, 30, 165, 166, 24, + 214, 48, 43, 25, 25, 25, 43, 25, 222, 41, + 224, 225, 85, 30, 30, 41, 201, 225, 63, 233, + 188, 170, 200, -1, 52, 239, -1, 241, -1, -1, + 198, 194, -1, -1, -1, 213, -1, -1, 0, 1, + -1, -1, 256, -1, 258, -1, -1, -1, 216, 11, + 12, 13, 14, -1, 16, 17, 18, 19, 20, -1, + 228, -1, 240, -1, 26, -1, 28, 29, 30, -1, + -1, 33, 34, 35, -1, -1, -1, -1, 40, 41, + 42, 251, -1, 45, -1, -1, -1, 49, 50, 51, + -1, -1, -1, -1, -1, -1, -1, -1, 60, -1, + -1, -1, 64, -1, -1, -1, 68, 69, -1, -1, + -1, 73, 74, 11, 12, 13, 14, -1, 16, 17, + 18, 19, 20, -1, -1, -1, -1, -1, 26, -1, + 28, 29, 30, -1, -1, 33, 34, 35, -1, -1, + -1, -1, 40, 41, 42, -1, -1, 45, -1, -1, + -1, 49, 50, 51, -1, -1, -1, -1, -1, -1, + -1, -1, 60, -1, -1, -1, 64, -1, -1, -1, + 68, 69, 11, 12, 13, 14, 74, 16, 17, 18, + 19, 20, -1, -1, -1, -1, -1, 26, -1, 28, + 29, 30, -1, -1, -1, 34, 35, -1, -1, -1, + -1, 40, 41, 42, -1, -1, 45, -1, -1, -1, + -1, -1, 51, -1, -1, -1, -1, -1, -1, -1, + -1, 60, -1, -1, -1, 64, -1, -1, -1, 68, + 69, -1, -1, -1, 73, 74, 11, 12, 13, 14, + -1, 16, 17, 18, 19, 20, -1, -1, -1, -1, + -1, 26, -1, 28, 29, 30, -1, -1, -1, 34, + 35, -1, -1, -1, -1, 40, 41, 42, -1, -1, + 45, -1, -1, -1, -1, -1, 51, -1, -1, -1, + -1, -1, -1, -1, -1, 60, -1, -1, -1, 64, + -1, -1, -1, 68, 69, 11, 12, 13, 14, 74, + 16, 17, 18, 19, 20, -1, -1, -1, -1, -1, + 26, -1, 28, 29, -1, -1, -1, -1, 34, 35, + 11, 12, 13, 14, 40, 16, 42, -1, 19, 20, + -1, 11, 12, 13, 14, 51, 16, -1, -1, 19, + 20, -1, -1, -1, 60, -1, -1, -1, 64, 40, + -1, 42, 68, 69, -1, -1, -1, -1, 74, -1, + 40, -1, 42, -1, -1, 31, -1, -1, -1, 60, + -1, -1, -1, 64, -1, -1, -1, 68, 69, -1, + 60, -1, -1, 74, 64, -1, 52, 53, 68, 69, + -1, 57, 58, 59, 74, 61, 62, 63, -1, -1, + 44, -1, 68, 69, 70, 71, -1, -1, 52, 53, + 76, 77, 78, 57, 58, 59, -1, 61, 62, 63, + -1, -1, -1, 67, 68, 69, 70, 71, -1, 46, + -1, -1, 76, 77, 78, 52, 53, -1, -1, -1, + 57, 58, 59, -1, 61, 62, 63, -1, -1, -1, + -1, 68, 69, 70, 71, -1, -1, 52, 53, 76, + 77, 78, 57, 58, 59, -1, 61, 62, 63, -1, + 65, 66, -1, 68, 69, 70, 71, -1, -1, 52, + 53, 76, 77, 78, 57, 58, 59, -1, 61, 62, + 63, -1, -1, -1, 67, 68, 69, 70, 71, -1, + -1, -1, 75, 76, 77, 78, 52, 53, -1, -1, + -1, 57, 58, 59, -1, 61, 62, 63, -1, -1, + -1, -1, 68, 69, 70, 71, -1, -1, -1, 75, + 76, 77, 78, 52, 53, -1, -1, -1, 57, 58, + 59, -1, 61, 62, 63, -1, -1, -1, 67, 68, + 69, 70, 71, -1, -1, 52, 53, 76, 77, 78, + 57, 58, 59, -1, 61, 62, 63, -1, -1, -1, + -1, 68, 69, 70, 71, -1, -1, 52, 53, 76, + 77, 78, 57, 58, 59, -1, 61, 62, 63, -1, + -1, -1, -1, -1, -1, 70, 71, -1, -1, 74, + -1, 76, 77, 78, 52, 53, -1, -1, -1, 57, + 58, 59, -1, 61, 62, 63, -1, -1, -1, -1, + -1, -1, 70, 71, -1, -1, -1, -1, 76, 77, + 78 }; /* YYSTOS[STATE-NUM] -- The (internal number of the) accessing @@ -956,30 +973,31 @@ static const yytype_uint8 yystos[] = { 0, 1, 11, 12, 13, 14, 16, 17, 18, 19, 20, 26, 28, 29, 30, 33, 34, 35, 40, 41, - 42, 45, 49, 50, 59, 63, 67, 68, 73, 80, - 82, 83, 84, 85, 86, 93, 94, 95, 100, 101, - 103, 106, 111, 72, 19, 40, 83, 100, 100, 100, - 73, 97, 19, 102, 20, 27, 32, 36, 37, 38, - 39, 44, 104, 105, 19, 20, 19, 100, 46, 47, - 12, 13, 19, 19, 19, 19, 100, 100, 100, 100, - 100, 0, 72, 81, 73, 66, 73, 92, 100, 51, - 52, 56, 57, 58, 60, 61, 62, 67, 68, 69, - 70, 75, 76, 77, 100, 100, 112, 112, 78, 20, - 20, 36, 20, 27, 36, 44, 105, 107, 31, 19, - 44, 66, 100, 44, 66, 43, 108, 64, 65, 74, - 82, 92, 100, 92, 100, 43, 66, 100, 100, 100, - 100, 100, 100, 100, 100, 100, 100, 100, 100, 100, - 100, 100, 74, 78, 19, 20, 20, 20, 97, 19, - 100, 100, 44, 66, 100, 100, 100, 97, 100, 100, - 74, 98, 74, 81, 97, 100, 100, 19, 109, 100, - 100, 109, 99, 22, 44, 99, 84, 101, 78, 81, - 81, 81, 85, 98, 44, 100, 98, 98, 19, 78, - 110, 110, 25, 100, 98, 25, 48, 97, 24, 48, - 89, 90, 96, 19, 99, 99, 41, 98, 99, 30, - 99, 88, 89, 91, 96, 97, 90, 98, 92, 99, - 98, 98, 91, 98, 92, 84, 48, 87, 43, 98, - 25, 25, 25, 43, 98, 97, 98, 97, 25, 41, - 30, 30, 99, 84, 85, 41, 98, 98 + 42, 45, 49, 50, 51, 60, 64, 68, 69, 74, + 81, 83, 84, 85, 86, 87, 94, 95, 96, 101, + 102, 104, 107, 112, 73, 19, 40, 84, 101, 101, + 101, 74, 98, 19, 103, 20, 27, 32, 36, 37, + 38, 39, 44, 105, 106, 19, 20, 19, 101, 46, + 47, 12, 13, 19, 19, 19, 19, 101, 101, 101, + 101, 101, 101, 0, 73, 82, 74, 67, 74, 93, + 101, 52, 53, 57, 58, 59, 61, 62, 63, 68, + 69, 70, 71, 76, 77, 78, 101, 101, 113, 113, + 79, 20, 20, 36, 20, 27, 36, 44, 106, 108, + 31, 19, 44, 67, 101, 44, 67, 43, 109, 46, + 65, 66, 75, 83, 93, 101, 93, 101, 43, 67, + 101, 101, 101, 101, 101, 101, 101, 101, 101, 101, + 101, 101, 101, 101, 101, 75, 79, 19, 20, 20, + 20, 98, 19, 101, 101, 44, 67, 101, 101, 101, + 98, 101, 101, 101, 75, 99, 75, 82, 98, 101, + 101, 19, 110, 101, 101, 110, 100, 22, 44, 100, + 85, 102, 79, 82, 82, 82, 86, 99, 44, 101, + 99, 99, 19, 79, 111, 111, 25, 101, 99, 25, + 48, 98, 24, 48, 90, 91, 97, 19, 100, 100, + 41, 99, 100, 30, 100, 89, 90, 92, 97, 98, + 91, 99, 93, 100, 99, 99, 92, 99, 93, 85, + 48, 88, 43, 99, 25, 25, 25, 43, 99, 98, + 99, 98, 25, 41, 30, 30, 100, 85, 86, 41, + 99, 99 }; #define yyerrok (yyerrstatus = 0) @@ -2321,32 +2339,42 @@ yyreduce: break; case 93: -#line 417 "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); ;} +#line 415 "engines/director/lingo/lingo-gr.y" + { g_lingo->code1(g_lingo->c_open); ;} break; case 94: -#line 418 "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 416 "engines/director/lingo/lingo-gr.y" + { g_lingo->code2(g_lingo->c_voidpush, g_lingo->c_open); ;} break; case 95: -#line 429 "engines/director/lingo/lingo-gr.y" - { g_lingo->code1(g_lingo->c_gotoloop); ;} +#line 419 "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 96: -#line 430 "engines/director/lingo/lingo-gr.y" - { g_lingo->code1(g_lingo->c_gotonext); ;} +#line 420 "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 97: #line 431 "engines/director/lingo/lingo-gr.y" - { g_lingo->code1(g_lingo->c_gotoprevious); ;} + { g_lingo->code1(g_lingo->c_gotoloop); ;} break; case 98: #line 432 "engines/director/lingo/lingo-gr.y" + { g_lingo->code1(g_lingo->c_gotonext); ;} + break; + + case 99: +#line 433 "engines/director/lingo/lingo-gr.y" + { g_lingo->code1(g_lingo->c_gotoprevious); ;} + break; + + case 100: +#line 434 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(g_lingo->c_goto); g_lingo->codeString((yyvsp[(2) - (2)].s)->c_str()); @@ -2354,8 +2382,8 @@ yyreduce: delete (yyvsp[(2) - (2)].s); ;} break; - case 99: -#line 437 "engines/director/lingo/lingo-gr.y" + case 101: +#line 439 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(g_lingo->c_goto); g_lingo->codeString((yyvsp[(2) - (3)].s)->c_str()); @@ -2364,8 +2392,8 @@ yyreduce: delete (yyvsp[(3) - (3)].s); ;} break; - case 100: -#line 443 "engines/director/lingo/lingo-gr.y" + case 102: +#line 445 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(g_lingo->c_goto); g_lingo->codeString(""); @@ -2373,48 +2401,48 @@ yyreduce: delete (yyvsp[(2) - (2)].s); ;} break; - case 101: -#line 450 "engines/director/lingo/lingo-gr.y" + case 103: +#line 452 "engines/director/lingo/lingo-gr.y" { (yyval.s) = (yyvsp[(3) - (3)].s); ;} break; - case 102: -#line 451 "engines/director/lingo/lingo-gr.y" + case 104: +#line 453 "engines/director/lingo/lingo-gr.y" { (yyval.s) = (yyvsp[(2) - (2)].s); ;} break; - case 103: -#line 452 "engines/director/lingo/lingo-gr.y" + case 105: +#line 454 "engines/director/lingo/lingo-gr.y" { (yyval.s) = (yyvsp[(2) - (2)].s); ;} break; - case 104: -#line 453 "engines/director/lingo/lingo-gr.y" + case 106: +#line 455 "engines/director/lingo/lingo-gr.y" { (yyval.s) = (yyvsp[(1) - (1)].s); ;} break; - case 105: -#line 456 "engines/director/lingo/lingo-gr.y" + case 107: +#line 458 "engines/director/lingo/lingo-gr.y" { (yyval.s) = (yyvsp[(3) - (3)].s); ;} break; - case 106: -#line 457 "engines/director/lingo/lingo-gr.y" + case 108: +#line 459 "engines/director/lingo/lingo-gr.y" { (yyval.s) = (yyvsp[(2) - (2)].s); ;} break; - case 107: -#line 458 "engines/director/lingo/lingo-gr.y" + case 109: +#line 460 "engines/director/lingo/lingo-gr.y" { (yyval.s) = (yyvsp[(3) - (3)].s); ;} break; - case 108: -#line 486 "engines/director/lingo/lingo-gr.y" + case 110: +#line 488 "engines/director/lingo/lingo-gr.y" { g_lingo->_indef = true; g_lingo->_currentFactory.clear(); ;} break; - case 109: -#line 487 "engines/director/lingo/lingo-gr.y" + case 111: +#line 489 "engines/director/lingo/lingo-gr.y" { g_lingo->codeConst(0); // Push fake value on stack g_lingo->code1(g_lingo->c_procret); @@ -2422,20 +2450,20 @@ yyreduce: g_lingo->_indef = false; ;} break; - case 110: -#line 492 "engines/director/lingo/lingo-gr.y" + case 112: +#line 494 "engines/director/lingo/lingo-gr.y" { g_lingo->codeFactory(*(yyvsp[(2) - (2)].s)); ;} break; - case 111: -#line 495 "engines/director/lingo/lingo-gr.y" + case 113: +#line 497 "engines/director/lingo/lingo-gr.y" { g_lingo->_indef = true; ;} break; - case 112: -#line 496 "engines/director/lingo/lingo-gr.y" + case 114: +#line 498 "engines/director/lingo/lingo-gr.y" { g_lingo->codeConst(0); // Push fake value on stack g_lingo->code1(g_lingo->c_procret); @@ -2443,33 +2471,33 @@ yyreduce: g_lingo->_indef = false; ;} break; - case 113: -#line 501 "engines/director/lingo/lingo-gr.y" + case 115: +#line 503 "engines/director/lingo/lingo-gr.y" { (yyval.narg) = 0; ;} break; - case 114: -#line 502 "engines/director/lingo/lingo-gr.y" + case 116: +#line 504 "engines/director/lingo/lingo-gr.y" { g_lingo->codeArg((yyvsp[(1) - (1)].s)); (yyval.narg) = 1; ;} break; - case 115: -#line 503 "engines/director/lingo/lingo-gr.y" + case 117: +#line 505 "engines/director/lingo/lingo-gr.y" { g_lingo->codeArg((yyvsp[(3) - (3)].s)); (yyval.narg) = (yyvsp[(1) - (3)].narg) + 1; ;} break; - case 116: -#line 504 "engines/director/lingo/lingo-gr.y" + case 118: +#line 506 "engines/director/lingo/lingo-gr.y" { g_lingo->codeArg((yyvsp[(4) - (4)].s)); (yyval.narg) = (yyvsp[(1) - (4)].narg) + 1; ;} break; - case 117: -#line 506 "engines/director/lingo/lingo-gr.y" + case 119: +#line 508 "engines/director/lingo/lingo-gr.y" { g_lingo->codeArgStore(); ;} break; - case 118: -#line 510 "engines/director/lingo/lingo-gr.y" + case 120: +#line 512 "engines/director/lingo/lingo-gr.y" { g_lingo->code1(g_lingo->c_call); g_lingo->codeString((yyvsp[(1) - (3)].s)->c_str()); @@ -2478,24 +2506,24 @@ yyreduce: g_lingo->code1(numpar); ;} break; - case 119: -#line 518 "engines/director/lingo/lingo-gr.y" + case 121: +#line 520 "engines/director/lingo/lingo-gr.y" { (yyval.narg) = 0; ;} break; - case 120: -#line 519 "engines/director/lingo/lingo-gr.y" + case 122: +#line 521 "engines/director/lingo/lingo-gr.y" { (yyval.narg) = 1; ;} break; - case 121: -#line 520 "engines/director/lingo/lingo-gr.y" + case 123: +#line 522 "engines/director/lingo/lingo-gr.y" { (yyval.narg) = (yyvsp[(1) - (3)].narg) + 1; ;} break; /* Line 1267 of yacc.c. */ -#line 2499 "engines/director/lingo/lingo-gr.cpp" +#line 2527 "engines/director/lingo/lingo-gr.cpp" default: break; } YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc); @@ -2709,6 +2737,6 @@ yyreturn: } -#line 523 "engines/director/lingo/lingo-gr.y" +#line 525 "engines/director/lingo/lingo-gr.y" diff --git a/engines/director/lingo/lingo-gr.h b/engines/director/lingo/lingo-gr.h index 6050189849..4969805d20 100644 --- a/engines/director/lingo/lingo-gr.h +++ b/engines/director/lingo/lingo-gr.h @@ -87,21 +87,22 @@ tNLELSE = 303, tFACTORY = 304, tMETHOD = 305, - tGE = 306, - tLE = 307, - tGT = 308, - tLT = 309, - tEQ = 310, - tNEQ = 311, - tAND = 312, - tOR = 313, - tNOT = 314, - tCONCAT = 315, - tCONTAINS = 316, - tSTARTS = 317, - tSPRITE = 318, - tINTERSECTS = 319, - tWITHIN = 320 + tOPEN = 306, + tGE = 307, + tLE = 308, + tGT = 309, + tLT = 310, + tEQ = 311, + tNEQ = 312, + tAND = 313, + tOR = 314, + tNOT = 315, + tCONCAT = 316, + tCONTAINS = 317, + tSTARTS = 318, + tSPRITE = 319, + tINTERSECTS = 320, + tWITHIN = 321 }; #endif /* Tokens. */ @@ -153,21 +154,22 @@ #define tNLELSE 303 #define tFACTORY 304 #define tMETHOD 305 -#define tGE 306 -#define tLE 307 -#define tGT 308 -#define tLT 309 -#define tEQ 310 -#define tNEQ 311 -#define tAND 312 -#define tOR 313 -#define tNOT 314 -#define tCONCAT 315 -#define tCONTAINS 316 -#define tSTARTS 317 -#define tSPRITE 318 -#define tINTERSECTS 319 -#define tWITHIN 320 +#define tOPEN 306 +#define tGE 307 +#define tLE 308 +#define tGT 309 +#define tLT 310 +#define tEQ 311 +#define tNEQ 312 +#define tAND 313 +#define tOR 314 +#define tNOT 315 +#define tCONCAT 316 +#define tCONTAINS 317 +#define tSTARTS 318 +#define tSPRITE 319 +#define tINTERSECTS 320 +#define tWITHIN 321 @@ -185,7 +187,7 @@ typedef union YYSTYPE Common::Array<double> *arr; } /* Line 1529 of yacc.c. */ -#line 189 "engines/director/lingo/lingo-gr.hpp" +#line 191 "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 89cbb0563c..786d243687 100644 --- a/engines/director/lingo/lingo-gr.y +++ b/engines/director/lingo/lingo-gr.y @@ -84,7 +84,7 @@ void yyerror(char *s) { %token<s> BLTIN BLTINNOARGS BLTINNOARGSORONE BLTINONEARG ID STRING HANDLER %token tDOWN tELSE tNLELSIF tEND tEXIT tFRAME tGLOBAL tGO tIF tINTO tLOOP tMACRO %token tMCI tMCIWAIT tMOVIE tNEXT tOF tPREVIOUS tPUT tREPEAT tSET tTHEN tTO tWHEN -%token tWITH tWHILE tNLELSE tFACTORY tMETHOD +%token tWITH tWHILE tNLELSE tFACTORY tMETHOD tOPEN %token tGE tLE tGT tLT tEQ tNEQ tAND tOR tNOT %token tCONCAT tCONTAINS tSTARTS %token tSPRITE tINTERSECTS tWITHIN @@ -412,6 +412,8 @@ func: tMCI STRING { g_lingo->code1(g_lingo->c_mci); g_lingo->codeString($2->c_ | BLTINNOARGSORONE { g_lingo->code2(g_lingo->c_voidpush, g_lingo->_handlers[*$1]->u.func); delete $1; } + | tOPEN expr tWITH expr { g_lingo->code1(g_lingo->c_open); } + | tOPEN expr { g_lingo->code2(g_lingo->c_voidpush, g_lingo->c_open); } ; globallist: ID { g_lingo->code1(g_lingo->c_global); g_lingo->codeString($1->c_str()); delete $1; } diff --git a/engines/director/lingo/lingo-lex.cpp b/engines/director/lingo/lingo-lex.cpp index 86f70de2e1..387fd67c0c 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 54 -#define YY_END_OF_BUFFER 55 +#define YY_NUM_RULES 55 +#define YY_END_OF_BUFFER 56 /* This struct is not used in this scanner, but its presence is necessary. */ struct yy_trans_info @@ -373,28 +373,28 @@ struct yy_trans_info flex_int32_t yy_verify; flex_int32_t yy_nxt; }; -static yyconst flex_int16_t yy_accept[186] = +static yyconst flex_int16_t yy_accept[189] = { 0, - 0, 0, 55, 53, 3, 51, 51, 53, 53, 50, - 50, 50, 49, 50, 50, 47, 47, 47, 47, 47, - 47, 47, 47, 47, 47, 47, 47, 47, 47, 47, - 47, 47, 2, 2, 3, 51, 0, 0, 51, 0, - 0, 52, 46, 1, 48, 49, 45, 43, 44, 47, - 47, 47, 47, 47, 47, 47, 47, 47, 47, 16, - 7, 47, 47, 47, 47, 47, 47, 47, 47, 27, - 28, 47, 47, 47, 47, 47, 47, 47, 37, 47, - 47, 2, 2, 0, 1, 48, 4, 47, 47, 47, - 11, 47, 47, 47, 47, 47, 47, 47, 21, 47, - - 47, 47, 26, 47, 30, 47, 32, 47, 47, 47, - 47, 47, 47, 0, 47, 6, 10, 13, 47, 47, - 47, 47, 18, 19, 47, 47, 47, 47, 25, 47, - 47, 47, 47, 0, 36, 41, 47, 39, 9, 47, - 47, 14, 47, 47, 20, 47, 47, 24, 47, 47, - 47, 47, 35, 42, 47, 0, 47, 47, 15, 47, - 47, 23, 47, 31, 38, 33, 0, 40, 0, 47, - 12, 47, 22, 47, 0, 8, 5, 47, 29, 0, - 47, 0, 17, 34, 0 + 0, 0, 56, 54, 3, 52, 52, 54, 54, 51, + 51, 51, 50, 51, 51, 48, 48, 48, 48, 48, + 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, + 48, 48, 2, 2, 3, 52, 0, 0, 52, 0, + 0, 53, 47, 1, 49, 50, 46, 44, 45, 48, + 48, 48, 48, 48, 48, 48, 48, 48, 48, 16, + 7, 48, 48, 48, 48, 48, 48, 48, 48, 27, + 48, 29, 48, 48, 48, 48, 48, 48, 48, 38, + 48, 48, 2, 2, 0, 1, 49, 4, 48, 48, + 48, 11, 48, 48, 48, 48, 48, 48, 48, 21, + + 48, 48, 48, 26, 48, 48, 31, 48, 33, 48, + 48, 48, 48, 48, 48, 0, 48, 6, 10, 13, + 48, 48, 48, 48, 18, 19, 48, 48, 48, 48, + 25, 28, 48, 48, 48, 48, 0, 37, 42, 48, + 40, 9, 48, 48, 14, 48, 48, 20, 48, 48, + 24, 48, 48, 48, 48, 36, 43, 48, 0, 48, + 48, 15, 48, 48, 23, 48, 32, 39, 34, 0, + 41, 0, 48, 12, 48, 22, 48, 0, 8, 5, + 48, 30, 0, 48, 0, 17, 35, 0 } ; static yyconst flex_int32_t yy_ec[256] = @@ -439,55 +439,59 @@ static yyconst flex_int32_t yy_meta[61] = 6, 6, 6, 6, 6, 6, 6, 6, 6, 6 } ; -static yyconst flex_int16_t yy_base[191] = +static yyconst flex_int16_t yy_base[194] = { 0, - 0, 59, 210, 446, 63, 67, 71, 75, 192, 446, - 150, 148, 52, 68, 137, 56, 0, 56, 57, 67, - 72, 68, 68, 69, 112, 70, 79, 103, 81, 109, - 120, 121, 170, 174, 178, 101, 182, 186, 190, 97, - 143, 446, 446, 0, 90, 124, 446, 446, 446, 0, - 112, 110, 104, 115, 147, 167, 179, 182, 119, 0, - 0, 167, 172, 184, 179, 172, 173, 172, 179, 0, - 0, 193, 183, 187, 185, 188, 198, 200, 0, 205, - 200, 242, 254, 211, 0, 80, 0, 217, 223, 232, - 0, 221, 222, 234, 245, 243, 235, 236, 232, 246, - - 246, 242, 0, 244, 0, 260, 0, 257, 252, 279, - 261, 266, 273, 277, 283, 0, 0, 0, 272, 283, - 292, 279, 0, 0, 282, 297, 287, 294, 0, 293, - 302, 289, 292, 201, 0, 0, 299, 302, 325, 305, - 304, 0, 310, 308, 0, 320, 327, 0, 320, 318, - 327, 320, 351, 0, 327, 358, 328, 322, 0, 342, - 332, 0, 332, 0, 0, 0, 370, 0, 346, 337, - 0, 359, 0, 348, 360, 446, 0, 351, 0, 384, - 353, 390, 0, 391, 446, 421, 423, 429, 434, 439 + 0, 59, 164, 454, 63, 67, 71, 75, 153, 454, + 144, 141, 52, 68, 124, 56, 0, 56, 57, 67, + 72, 68, 68, 69, 112, 70, 104, 105, 80, 117, + 119, 120, 171, 175, 179, 97, 183, 187, 191, 80, + 116, 454, 454, 0, 93, 134, 454, 454, 454, 0, + 112, 82, 104, 137, 172, 174, 181, 184, 173, 0, + 0, 170, 175, 187, 182, 176, 175, 176, 181, 0, + 196, 0, 197, 186, 190, 188, 197, 218, 218, 0, + 225, 214, 249, 260, 216, 0, 80, 0, 223, 229, + 230, 0, 226, 227, 234, 250, 248, 242, 244, 240, + + 255, 257, 252, 0, 258, 252, 0, 268, 0, 265, + 262, 291, 273, 277, 267, 276, 288, 0, 0, 0, + 277, 287, 295, 284, 0, 0, 288, 305, 289, 302, + 0, 0, 299, 309, 294, 297, 330, 0, 0, 312, + 310, 345, 313, 308, 0, 317, 312, 0, 328, 335, + 0, 328, 326, 335, 328, 362, 0, 335, 366, 336, + 332, 0, 351, 340, 0, 340, 0, 0, 0, 378, + 0, 354, 345, 0, 367, 0, 356, 368, 454, 0, + 359, 0, 388, 366, 398, 0, 399, 454, 429, 431, + 437, 442, 447 + } ; -static yyconst flex_int16_t yy_def[191] = +static yyconst flex_int16_t yy_def[194] = { 0, - 185, 1, 185, 185, 185, 185, 185, 185, 186, 185, - 185, 185, 185, 185, 185, 187, 187, 187, 187, 187, - 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, - 187, 187, 185, 185, 185, 185, 185, 185, 185, 185, - 186, 185, 185, 188, 185, 185, 185, 185, 185, 187, - 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, - 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, - 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, - 187, 185, 185, 185, 188, 185, 187, 187, 187, 187, - 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, - - 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, - 187, 187, 187, 185, 187, 187, 187, 187, 187, 187, - 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, - 187, 187, 187, 189, 187, 187, 187, 187, 185, 187, - 187, 187, 187, 187, 187, 187, 187, 187, 187, 187, - 187, 187, 189, 187, 187, 185, 187, 187, 187, 187, - 187, 187, 187, 187, 187, 187, 185, 187, 185, 187, - 187, 187, 187, 187, 185, 185, 187, 187, 187, 185, - 187, 190, 187, 190, 0, 185, 185, 185, 185, 185 + 188, 1, 188, 188, 188, 188, 188, 188, 189, 188, + 188, 188, 188, 188, 188, 190, 190, 190, 190, 190, + 190, 190, 190, 190, 190, 190, 190, 190, 190, 190, + 190, 190, 188, 188, 188, 188, 188, 188, 188, 188, + 189, 188, 188, 191, 188, 188, 188, 188, 188, 190, + 190, 190, 190, 190, 190, 190, 190, 190, 190, 190, + 190, 190, 190, 190, 190, 190, 190, 190, 190, 190, + 190, 190, 190, 190, 190, 190, 190, 190, 190, 190, + 190, 190, 188, 188, 188, 191, 188, 190, 190, 190, + 190, 190, 190, 190, 190, 190, 190, 190, 190, 190, + + 190, 190, 190, 190, 190, 190, 190, 190, 190, 190, + 190, 190, 190, 190, 190, 188, 190, 190, 190, 190, + 190, 190, 190, 190, 190, 190, 190, 190, 190, 190, + 190, 190, 190, 190, 190, 190, 192, 190, 190, 190, + 190, 188, 190, 190, 190, 190, 190, 190, 190, 190, + 190, 190, 190, 190, 190, 192, 190, 190, 188, 190, + 190, 190, 190, 190, 190, 190, 190, 190, 190, 188, + 190, 188, 190, 190, 190, 190, 190, 188, 188, 190, + 190, 190, 188, 190, 193, 190, 193, 0, 188, 188, + 188, 188, 188 + } ; -static yyconst flex_int16_t yy_nxt[507] = +static yyconst flex_int16_t yy_nxt[515] = { 0, 4, 5, 6, 7, 8, 9, 10, 11, 12, 4, 13, 14, 10, 15, 16, 17, 18, 19, 20, 21, @@ -498,56 +502,57 @@ static yyconst flex_int16_t yy_nxt[507] = 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, 68, 40, - 86, 54, 59, 55, 62, 60, 63, 69, 70, 74, + 87, 54, 59, 55, 62, 60, 63, 69, 75, 36, - 86, 58, 56, 36, 36, 51, 52, 53, 71, 40, + 36, 58, 56, 87, 85, 51, 52, 53, 89, 40, 57, 61, 68, 40, 54, 59, 55, 62, 60, 63, - 69, 84, 70, 74, 58, 56, 64, 75, 65, 87, - 66, 71, 72, 45, 46, 73, 88, 76, 89, 67, - 77, 78, 80, 81, 84, 90, 95, 79, 42, 49, - 64, 75, 65, 87, 66, 72, 44, 43, 73, 88, - 76, 89, 67, 77, 91, 78, 80, 81, 90, 95, - 79, 82, 36, 36, 83, 83, 36, 36, 83, 35, - 36, 36, 37, 37, 36, 36, 37, 38, 91, 92, - 38, 38, 39, 39, 38, 93, 94, 42, 96, 97, - - 98, 99, 134, 100, 40, 134, 101, 102, 40, 185, - 103, 104, 109, 92, 105, 106, 107, 108, 110, 93, - 94, 96, 97, 111, 98, 99, 100, 112, 40, 101, - 102, 113, 40, 103, 185, 104, 109, 105, 106, 107, - 108, 114, 110, 82, 36, 36, 83, 111, 115, 116, - 117, 112, 118, 119, 113, 83, 36, 36, 83, 120, - 121, 122, 185, 124, 114, 125, 126, 127, 128, 185, - 123, 115, 116, 129, 117, 118, 119, 130, 131, 132, - 134, 133, 120, 134, 121, 122, 124, 136, 125, 126, - 137, 127, 128, 123, 138, 139, 129, 140, 185, 141, - - 130, 142, 131, 132, 133, 135, 143, 185, 144, 145, - 136, 146, 148, 137, 147, 149, 150, 154, 138, 139, - 151, 140, 141, 152, 155, 142, 156, 157, 135, 156, - 143, 144, 145, 158, 159, 146, 148, 147, 160, 149, - 150, 154, 161, 151, 162, 165, 152, 163, 155, 164, - 166, 157, 167, 168, 170, 167, 158, 159, 171, 156, - 172, 160, 156, 173, 174, 176, 161, 177, 162, 165, - 163, 167, 164, 166, 167, 178, 168, 170, 179, 180, - 169, 171, 181, 183, 172, 182, 173, 174, 182, 176, - 177, 182, 185, 185, 182, 185, 185, 175, 185, 178, - - 185, 179, 185, 180, 169, 181, 183, 185, 185, 185, - 185, 185, 185, 185, 185, 185, 185, 185, 185, 185, - 175, 41, 41, 185, 41, 41, 41, 50, 50, 85, - 85, 185, 185, 85, 85, 153, 185, 185, 185, 153, - 184, 185, 185, 185, 184, 3, 185, 185, 185, 185, - 185, 185, 185, 185, 185, 185, 185, 185, 185, 185, - 185, 185, 185, 185, 185, 185, 185, 185, 185, 185, - 185, 185, 185, 185, 185, 185, 185, 185, 185, 185, - 185, 185, 185, 185, 185, 185, 185, 185, 185, 185, - 185, 185, 185, 185, 185, 185, 185, 185, 185, 185, - - 185, 185, 185, 185, 185, 185 + 69, 42, 75, 70, 58, 56, 64, 85, 65, 88, + 66, 89, 71, 72, 73, 76, 49, 74, 90, 67, + 79, 81, 82, 45, 46, 77, 80, 70, 78, 44, + 64, 43, 65, 88, 66, 71, 72, 73, 42, 76, + 74, 90, 67, 188, 79, 81, 82, 91, 77, 80, + 188, 78, 83, 36, 36, 84, 84, 36, 36, 84, + 35, 36, 36, 37, 37, 36, 36, 37, 38, 92, + 91, 38, 38, 39, 39, 38, 93, 94, 95, 188, + + 96, 97, 98, 99, 100, 40, 188, 101, 102, 40, + 188, 103, 104, 92, 105, 106, 188, 107, 108, 109, + 93, 94, 95, 96, 97, 98, 110, 99, 100, 40, + 101, 102, 111, 40, 103, 104, 112, 188, 105, 106, + 107, 108, 109, 113, 188, 115, 116, 114, 119, 110, + 83, 36, 36, 84, 117, 118, 111, 120, 121, 122, + 112, 84, 36, 36, 84, 123, 124, 113, 115, 116, + 126, 114, 119, 127, 128, 125, 129, 117, 118, 130, + 120, 121, 122, 131, 132, 133, 134, 135, 141, 123, + 124, 136, 137, 126, 142, 137, 127, 128, 125, 139, + + 129, 140, 143, 130, 144, 145, 131, 132, 133, 146, + 134, 135, 141, 147, 136, 148, 150, 138, 142, 149, + 151, 152, 139, 153, 140, 154, 143, 144, 155, 145, + 157, 137, 158, 146, 137, 160, 147, 161, 148, 150, + 138, 162, 163, 149, 151, 152, 159, 153, 154, 159, + 164, 155, 165, 168, 157, 166, 158, 167, 169, 160, + 161, 171, 173, 170, 162, 163, 170, 159, 174, 175, + 159, 176, 177, 179, 164, 180, 165, 168, 166, 170, + 167, 169, 170, 181, 171, 173, 182, 183, 172, 185, + 184, 174, 185, 175, 176, 177, 186, 179, 180, 185, + + 188, 188, 185, 188, 188, 178, 188, 181, 188, 182, + 188, 183, 172, 184, 188, 188, 188, 188, 188, 186, + 188, 188, 188, 188, 188, 188, 188, 188, 178, 41, + 41, 188, 41, 41, 41, 50, 50, 86, 86, 188, + 188, 86, 86, 156, 188, 188, 188, 156, 187, 188, + 188, 188, 187, 3, 188, 188, 188, 188, 188, 188, + 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, + 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, + 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, + 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, + + 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, + 188, 188, 188, 188 } ; -static yyconst flex_int16_t yy_chk[507] = +static yyconst flex_int16_t yy_chk[515] = { 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, @@ -558,53 +563,54 @@ static yyconst flex_int16_t yy_chk[507] = 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, 26, 7, - 86, 20, 22, 20, 23, 22, 24, 26, 27, 29, + 87, 20, 22, 20, 23, 22, 24, 26, 29, 36, - 45, 21, 20, 36, 36, 16, 18, 19, 27, 6, + 36, 21, 20, 45, 40, 16, 18, 19, 52, 6, 21, 23, 26, 7, 20, 22, 20, 23, 22, 24, - 26, 40, 27, 29, 21, 20, 25, 30, 25, 51, - 25, 27, 28, 46, 46, 28, 52, 30, 53, 25, - 30, 31, 32, 32, 40, 54, 59, 31, 41, 15, - 25, 30, 25, 51, 25, 28, 12, 11, 28, 52, - 30, 53, 25, 30, 55, 31, 32, 32, 54, 59, - 31, 33, 33, 33, 33, 34, 34, 34, 34, 35, - 35, 35, 35, 37, 37, 37, 37, 38, 55, 56, - 38, 39, 39, 39, 39, 57, 58, 9, 62, 63, - - 64, 65, 134, 66, 38, 134, 67, 68, 39, 3, - 69, 72, 77, 56, 73, 74, 75, 76, 78, 57, - 58, 62, 63, 80, 64, 65, 66, 80, 38, 67, - 68, 81, 39, 69, 0, 72, 77, 73, 74, 75, - 76, 84, 78, 82, 82, 82, 82, 80, 88, 89, - 90, 80, 92, 93, 81, 83, 83, 83, 83, 94, - 95, 96, 0, 97, 84, 98, 99, 100, 101, 0, - 96, 88, 89, 102, 90, 92, 93, 104, 106, 108, - 110, 109, 94, 110, 95, 96, 97, 111, 98, 99, - 112, 100, 101, 96, 113, 114, 102, 115, 0, 119, - - 104, 120, 106, 108, 109, 110, 121, 0, 122, 125, - 111, 126, 128, 112, 127, 130, 131, 137, 113, 114, - 132, 115, 119, 133, 138, 120, 139, 140, 110, 139, - 121, 122, 125, 141, 143, 126, 128, 127, 144, 130, - 131, 137, 146, 132, 147, 151, 133, 149, 138, 150, - 152, 140, 153, 155, 157, 153, 141, 143, 158, 156, - 160, 144, 156, 161, 163, 169, 146, 170, 147, 151, - 149, 167, 150, 152, 167, 172, 155, 157, 174, 175, - 156, 158, 178, 181, 160, 180, 161, 163, 180, 169, - 170, 182, 184, 0, 182, 184, 0, 167, 0, 172, - - 0, 174, 0, 175, 156, 178, 181, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 167, 186, 186, 0, 186, 186, 186, 187, 187, 188, - 188, 0, 0, 188, 188, 189, 0, 0, 0, 189, - 190, 0, 0, 0, 190, 185, 185, 185, 185, 185, - 185, 185, 185, 185, 185, 185, 185, 185, 185, 185, - 185, 185, 185, 185, 185, 185, 185, 185, 185, 185, - 185, 185, 185, 185, 185, 185, 185, 185, 185, 185, - 185, 185, 185, 185, 185, 185, 185, 185, 185, 185, - 185, 185, 185, 185, 185, 185, 185, 185, 185, 185, - - 185, 185, 185, 185, 185, 185 + 26, 41, 29, 27, 21, 20, 25, 40, 25, 51, + 25, 52, 27, 27, 28, 30, 15, 28, 53, 25, + 31, 32, 32, 46, 46, 30, 31, 27, 30, 12, + 25, 11, 25, 51, 25, 27, 27, 28, 9, 30, + 28, 53, 25, 3, 31, 32, 32, 54, 30, 31, + 0, 30, 33, 33, 33, 33, 34, 34, 34, 34, + 35, 35, 35, 35, 37, 37, 37, 37, 38, 55, + 54, 38, 39, 39, 39, 39, 56, 57, 58, 0, + + 59, 62, 63, 64, 65, 38, 0, 66, 67, 39, + 0, 68, 69, 55, 71, 73, 0, 74, 75, 76, + 56, 57, 58, 59, 62, 63, 77, 64, 65, 38, + 66, 67, 78, 39, 68, 69, 79, 0, 71, 73, + 74, 75, 76, 81, 0, 82, 85, 81, 91, 77, + 83, 83, 83, 83, 89, 90, 78, 93, 94, 95, + 79, 84, 84, 84, 84, 96, 97, 81, 82, 85, + 98, 81, 91, 99, 100, 97, 101, 89, 90, 102, + 93, 94, 95, 103, 105, 106, 108, 110, 115, 96, + 97, 111, 112, 98, 116, 112, 99, 100, 97, 113, + + 101, 114, 117, 102, 121, 122, 103, 105, 106, 123, + 108, 110, 115, 124, 111, 127, 129, 112, 116, 128, + 130, 133, 113, 134, 114, 135, 117, 121, 136, 122, + 140, 137, 141, 123, 137, 143, 124, 144, 127, 129, + 112, 146, 147, 128, 130, 133, 142, 134, 135, 142, + 149, 136, 150, 154, 140, 152, 141, 153, 155, 143, + 144, 158, 160, 156, 146, 147, 156, 159, 161, 163, + 159, 164, 166, 172, 149, 173, 150, 154, 152, 170, + 153, 155, 170, 175, 158, 160, 177, 178, 159, 183, + 181, 161, 183, 163, 164, 166, 184, 172, 173, 185, + + 187, 0, 185, 187, 0, 170, 0, 175, 0, 177, + 0, 178, 159, 181, 0, 0, 0, 0, 0, 184, + 0, 0, 0, 0, 0, 0, 0, 0, 170, 189, + 189, 0, 189, 189, 189, 190, 190, 191, 191, 0, + 0, 191, 191, 192, 0, 0, 0, 192, 193, 0, + 0, 0, 193, 188, 188, 188, 188, 188, 188, 188, + 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, + 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, + 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, + 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, + + 188, 188, 188, 188, 188, 188, 188, 188, 188, 188, + 188, 188, 188, 188 } ; static yy_state_type yy_last_accepting_state; @@ -678,7 +684,7 @@ static void countnl() { g_lingo->_colnumber = strlen(p); } -#line 682 "engines/director/lingo/lingo-lex.cpp" +#line 688 "engines/director/lingo/lingo-lex.cpp" #define INITIAL 0 @@ -866,7 +872,7 @@ YY_DECL #line 69 "engines/director/lingo/lingo-lex.l" -#line 870 "engines/director/lingo/lingo-lex.cpp" +#line 876 "engines/director/lingo/lingo-lex.cpp" if ( !(yy_init) ) { @@ -920,13 +926,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 >= 186 ) + if ( yy_current_state >= 189 ) 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] != 446 ); + while ( yy_base[yy_current_state] != 454 ); yy_find_action: yy_act = yy_accept[yy_current_state]; @@ -1090,36 +1096,41 @@ YY_RULE_SETUP case 28: YY_RULE_SETUP #line 99 "engines/director/lingo/lingo-lex.l" -{ count(); return tOR; } +{ count(); return tOPEN; } YY_BREAK case 29: YY_RULE_SETUP #line 100 "engines/director/lingo/lingo-lex.l" -{ count(); return tPREVIOUS; } +{ count(); return tOR; } YY_BREAK case 30: YY_RULE_SETUP #line 101 "engines/director/lingo/lingo-lex.l" -{ count(); return tPUT; } +{ count(); return tPREVIOUS; } YY_BREAK case 31: YY_RULE_SETUP #line 102 "engines/director/lingo/lingo-lex.l" -{ count(); return tREPEAT; } +{ count(); return tPUT; } YY_BREAK case 32: YY_RULE_SETUP #line 103 "engines/director/lingo/lingo-lex.l" -{ count(); return tSET; } +{ count(); return tREPEAT; } YY_BREAK case 33: YY_RULE_SETUP #line 104 "engines/director/lingo/lingo-lex.l" -{ count(); return tSTARTS; } +{ count(); return tSET; } YY_BREAK case 34: YY_RULE_SETUP #line 105 "engines/director/lingo/lingo-lex.l" +{ count(); return tSTARTS; } + YY_BREAK +case 35: +YY_RULE_SETUP +#line 106 "engines/director/lingo/lingo-lex.l" { count(); @@ -1161,9 +1172,9 @@ YY_RULE_SETUP warning("Unhandled the entity %s", ptr); } YY_BREAK -case 35: +case 36: YY_RULE_SETUP -#line 145 "engines/director/lingo/lingo-lex.l" +#line 146 "engines/director/lingo/lingo-lex.l" { count(); @@ -1184,64 +1195,64 @@ YY_RULE_SETUP warning("Unhandled the entity %s", ptr); } YY_BREAK -case 36: -YY_RULE_SETUP -#line 164 "engines/director/lingo/lingo-lex.l" -{ count(); return tTHEN; } - YY_BREAK case 37: YY_RULE_SETUP #line 165 "engines/director/lingo/lingo-lex.l" -{ count(); return tTO; } +{ count(); return tTHEN; } YY_BREAK case 38: YY_RULE_SETUP #line 166 "engines/director/lingo/lingo-lex.l" -{ count(); return tSPRITE; } +{ count(); return tTO; } YY_BREAK case 39: YY_RULE_SETUP #line 167 "engines/director/lingo/lingo-lex.l" -{ count(); return tWITH; } +{ count(); return tSPRITE; } YY_BREAK case 40: YY_RULE_SETUP #line 168 "engines/director/lingo/lingo-lex.l" -{ count(); return tWITHIN; } +{ count(); return tWITH; } YY_BREAK case 41: YY_RULE_SETUP #line 169 "engines/director/lingo/lingo-lex.l" -{ count(); return tWHEN; } +{ count(); return tWITHIN; } YY_BREAK case 42: YY_RULE_SETUP #line 170 "engines/director/lingo/lingo-lex.l" -{ count(); return tWHILE; } +{ count(); return tWHEN; } YY_BREAK case 43: YY_RULE_SETUP -#line 172 "engines/director/lingo/lingo-lex.l" -{ count(); return tNEQ; } +#line 171 "engines/director/lingo/lingo-lex.l" +{ count(); return tWHILE; } YY_BREAK case 44: YY_RULE_SETUP #line 173 "engines/director/lingo/lingo-lex.l" -{ count(); return tGE; } +{ count(); return tNEQ; } YY_BREAK case 45: YY_RULE_SETUP #line 174 "engines/director/lingo/lingo-lex.l" -{ count(); return tLE; } +{ count(); return tGE; } YY_BREAK case 46: YY_RULE_SETUP #line 175 "engines/director/lingo/lingo-lex.l" -{ count(); return tCONCAT; } +{ count(); return tLE; } YY_BREAK case 47: YY_RULE_SETUP -#line 177 "engines/director/lingo/lingo-lex.l" +#line 176 "engines/director/lingo/lingo-lex.l" +{ count(); return tCONCAT; } + YY_BREAK +case 48: +YY_RULE_SETUP +#line 178 "engines/director/lingo/lingo-lex.l" { count(); yylval.s = new Common::String(yytext); @@ -1267,43 +1278,43 @@ YY_RULE_SETUP return ID; } YY_BREAK -case 48: -YY_RULE_SETUP -#line 201 "engines/director/lingo/lingo-lex.l" -{ count(); yylval.f = atof(yytext); return FLOAT; } - YY_BREAK case 49: YY_RULE_SETUP #line 202 "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 50: YY_RULE_SETUP #line 203 "engines/director/lingo/lingo-lex.l" -{ count(); return *yytext; } +{ count(); yylval.i = strtol(yytext, NULL, 10); return INT; } YY_BREAK case 51: -/* rule 51 can match eol */ YY_RULE_SETUP #line 204 "engines/director/lingo/lingo-lex.l" -{ return '\n'; } +{ count(); return *yytext; } YY_BREAK case 52: +/* rule 52 can match eol */ YY_RULE_SETUP #line 205 "engines/director/lingo/lingo-lex.l" -{ count(); yylval.s = new Common::String(&yytext[1]); yylval.s->deleteLastChar(); return STRING; } +{ return '\n'; } YY_BREAK case 53: YY_RULE_SETUP #line 206 "engines/director/lingo/lingo-lex.l" - +{ count(); yylval.s = new Common::String(&yytext[1]); yylval.s->deleteLastChar(); return STRING; } YY_BREAK case 54: YY_RULE_SETUP -#line 208 "engines/director/lingo/lingo-lex.l" +#line 207 "engines/director/lingo/lingo-lex.l" + + YY_BREAK +case 55: +YY_RULE_SETUP +#line 209 "engines/director/lingo/lingo-lex.l" ECHO; YY_BREAK -#line 1307 "engines/director/lingo/lingo-lex.cpp" +#line 1318 "engines/director/lingo/lingo-lex.cpp" case YY_STATE_EOF(INITIAL): yyterminate(); @@ -1596,7 +1607,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 >= 186 ) + if ( yy_current_state >= 189 ) yy_c = yy_meta[(unsigned int) yy_c]; } yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c]; @@ -1624,11 +1635,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 >= 186 ) + if ( yy_current_state >= 189 ) 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 == 185); + yy_is_jam = (yy_current_state == 188); return yy_is_jam ? 0 : yy_current_state; } @@ -2303,7 +2314,7 @@ void yyfree (void * ptr ) #define YYTABLES_NAME "yytables" -#line 208 "engines/director/lingo/lingo-lex.l" +#line 209 "engines/director/lingo/lingo-lex.l" diff --git a/engines/director/lingo/lingo-lex.l b/engines/director/lingo/lingo-lex.l index 87954642fe..4f539c6048 100644 --- a/engines/director/lingo/lingo-lex.l +++ b/engines/director/lingo/lingo-lex.l @@ -96,6 +96,7 @@ whitespace [\t ] (?i:next) { count(); return tNEXT; } (?i:not) { count(); return tNOT; } (?i:of) { count(); return tOF; } +(?i:open) { count(); return tOPEN; } (?i:or) { count(); return tOR; } (?i:previous) { count(); return tPREVIOUS; } (?i:put) { count(); return tPUT; } diff --git a/engines/director/lingo/lingo.h b/engines/director/lingo/lingo.h index 4fa1d6410b..cda21dbe85 100644 --- a/engines/director/lingo/lingo.h +++ b/engines/director/lingo/lingo.h @@ -249,6 +249,8 @@ public: static void c_gotoprevious(); static void c_global(); + static void c_open(); + static void b_abs(); static void b_atan(); static void b_chars(); @@ -282,6 +284,7 @@ public: static void b_closeXlib(); static void b_cursor(); static void b_delay(); + static void b_do(); static void b_point(); diff --git a/engines/director/lingo/tests/builtin.lingo b/engines/director/lingo/tests/builtin.lingo index 5d427ba73d..b8cdf21b80 100644 --- a/engines/director/lingo/tests/builtin.lingo +++ b/engines/director/lingo/tests/builtin.lingo @@ -2,3 +2,7 @@ beep beep 3 alert "Hi" alert "Hi" && "there" + +open "Hello" +open "Hello" with "Finder" +open "Hello" && "more" with "Finder" |