diff options
author | Eugene Sandulenko | 2016-07-05 00:40:26 +0200 |
---|---|---|
committer | Eugene Sandulenko | 2016-08-03 23:40:36 +0200 |
commit | aac3497b739fb43c2ec232b1b53e317315071d4e (patch) | |
tree | a8c9f7a0b94e7fa9a85dc377da860c72de1bea57 | |
parent | b5cfcd05f67c4426b277b78f2d4fee86becc0365 (diff) | |
download | scummvm-rg350-aac3497b739fb43c2ec232b1b53e317315071d4e.tar.gz scummvm-rg350-aac3497b739fb43c2ec232b1b53e317315071d4e.tar.bz2 scummvm-rg350-aac3497b739fb43c2ec232b1b53e317315071d4e.zip |
DIRECTOR: Lingo: Switched elsestmt rule to left recursion for more effectiveness
-rw-r--r-- | engines/director/lingo/lingo-gr.cpp | 20 | ||||
-rw-r--r-- | engines/director/lingo/lingo-gr.y | 2 |
2 files changed, 11 insertions, 11 deletions
diff --git a/engines/director/lingo/lingo-gr.cpp b/engines/director/lingo/lingo-gr.cpp index 8cad3b90af..959f0b61c0 100644 --- a/engines/director/lingo/lingo-gr.cpp +++ b/engines/director/lingo/lingo-gr.cpp @@ -515,8 +515,8 @@ static const yytype_int8 yyrhs[] = 60, 71, 50, 14, 70, 60, 71, 50, -1, 68, 65, 34, 72, 71, 16, 21, -1, 68, 65, 34, 72, 71, 14, 72, 71, 16, 21, -1, 68, 65, - 34, 72, 71, 70, 63, 71, 16, 21, -1, 64, - 63, -1, 64, -1, 69, 65, 34, 70, 60, 71, + 34, 72, 71, 70, 63, 71, 16, 21, -1, 63, + 64, -1, 64, -1, 69, 65, 34, 70, 60, 71, 50, -1, 69, 65, 34, 72, 71, -1, 73, -1, 73, 44, 73, -1, 51, 65, 52, -1, 32, 37, -1, 32, 36, 10, -1, 21, -1, 15, -1, -1, @@ -641,7 +641,7 @@ static const yytype_uint8 yydefact[] = 41, 37, 87, 0, 0, 0, 38, 21, 0, 39, 0, 0, 0, 39, 85, 0, 38, 39, 0, 39, 38, 23, 36, 38, 27, 0, 86, 82, 18, 39, - 38, 37, 0, 0, 26, 0, 38, 0, 0, 0, + 38, 37, 0, 26, 0, 0, 38, 0, 0, 0, 0, 37, 0, 0, 38, 24, 25, 0, 38, 0, 19, 0, 38, 29, 20, 22, 0, 28 }; @@ -675,8 +675,8 @@ static const yytype_int16 yypact[] = 266, -89, 32, 183, 121, 134, -89, 166, -89, -89, -89, 34, 106, 156, 152, 134, 266, 122, 143, -89, 160, 167, 176, -89, -89, 162, 266, -89, 181, -89, - 183, -89, -89, -89, 167, 166, -89, 183, -89, -89, - 183, -89, 180, 182, -89, 171, 183, 185, 228, 186, + 183, -89, -89, 167, -89, 166, -89, 183, -89, -89, + 183, -89, 180, -89, 182, 171, 183, 185, 228, 186, 189, 24, 190, 187, -89, -89, -89, 228, 183, 188, -89, 163, -89, -89, -89, -89, 168, -89 }; @@ -684,7 +684,7 @@ static const yytype_int16 yypact[] = /* YYPGOTO[NTERM-NUM]. */ static const yytype_int16 yypgoto[] = { - -89, -89, 159, 10, 0, -89, -89, 58, -89, -62, + -89, -89, 159, 10, 0, -89, -89, -89, 59, -62, -89, -89, 15, -89, -88, -55, -69, -5, 17, -89, -89, -89, 177, -89, -89, -89, -89, -89, 62 }; @@ -706,7 +706,7 @@ static const yytype_int16 yytable[] = 111, 112, 21, 141, -39, 148, 57, 27, 144, 29, 160, 147, 142, 178, 167, 55, 56, 143, 170, 122, 123, 157, 63, 187, 64, 85, 79, 80, 129, 81, - 176, 169, 86, 175, 84, 172, 82, 38, 173, 130, + 176, 169, 86, 175, 84, 172, 82, 38, 174, 130, 83, 87, 188, 93, 39, 177, 34, 102, 114, 40, 41, 182, 43, 41, 42, 43, 44, 136, 88, 191, 146, 45, 67, 193, 116, 87, 117, 196, -4, 1, @@ -718,7 +718,7 @@ static const yytype_int16 yytable[] = 2, 3, 4, 51, 168, 171, 179, 52, 180, 15, 6, 183, 7, 8, 9, 181, 189, 185, 11, 12, 186, 16, 17, 195, 13, 14, 15, 65, 197, 190, - 194, 97, 174, 89, 0, 0, 0, 0, 16, 17, + 194, 97, 173, 89, 0, 0, 0, 0, 16, 17, 0, 0, 0, 139, 18, 2, 3, 4, 51, 0, 0, 68, 69, 0, 0, 6, 70, 7, 8, 9, 73, 74, 0, 11, 12, 0, 75, 76, 0, 13, @@ -756,7 +756,7 @@ static const yytype_int16 yycheck[] = 7, 8, 9, 10, 32, 14, 16, 31, 16, 33, 17, 16, 19, 20, 21, 34, 16, 21, 25, 26, 21, 45, 46, 50, 31, 32, 33, 51, 50, 32, - 32, 62, 164, 46, -1, -1, -1, -1, 45, 46, + 32, 62, 163, 46, -1, -1, -1, -1, 45, 46, -1, -1, -1, 50, 51, 7, 8, 9, 10, -1, -1, 38, 39, -1, -1, 17, 43, 19, 20, 21, 47, 48, -1, 25, 26, -1, 53, 54, -1, 31, @@ -791,7 +791,7 @@ static const yytype_uint8 yystos[] = 60, 71, 50, 55, 71, 35, 73, 71, 65, 14, 16, 70, 55, 82, 10, 16, 73, 71, 50, 34, 72, 21, 15, 63, 64, 69, 10, 72, 32, 71, - 72, 14, 71, 71, 63, 65, 72, 71, 70, 16, + 72, 14, 71, 64, 71, 65, 72, 71, 70, 16, 16, 34, 71, 16, 60, 21, 21, 70, 72, 16, 32, 71, 60, 71, 32, 50, 71, 50 }; diff --git a/engines/director/lingo/lingo-gr.y b/engines/director/lingo/lingo-gr.y index afd663d612..fd5245d78b 100644 --- a/engines/director/lingo/lingo-gr.y +++ b/engines/director/lingo/lingo-gr.y @@ -219,7 +219,7 @@ ifstmt: if cond tTHEN stmtlist end tEND tIF { g_lingo->processIf(0, $8); } ; -elseifstmt: elseifstmt1 elseifstmt +elseifstmt: elseifstmt elseifstmt1 | elseifstmt1 ; |