[Scummvm-git-logs] scummvm master -> 88060db8e2ec3e7d8a055dba371528ee928a240f
sev-
sev at scummvm.org
Mon Jan 13 00:18:15 UTC 2020
This automated email contains information about 2 new commits which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .
Summary:
657b049113 DIRECTOR: LINGO: Fixed preprocessor for correctly searching token boundaries
88060db8e2 DIRECTOR: LINGO: Added test for 'return' without spaces
Commit: 657b049113bf47c866b2bee65d300d129e92c6b9
https://github.com/scummvm/scummvm/commit/657b049113bf47c866b2bee65d300d129e92c6b9
Author: Eugene Sandulenko (sev at scummvm.org)
Date: 2020-01-13T01:16:29+01:00
Commit Message:
DIRECTOR: LINGO: Fixed preprocessor for correctly searching token boundaries
Changed paths:
engines/director/lingo/lingo-preprocessor.cpp
diff --git a/engines/director/lingo/lingo-preprocessor.cpp b/engines/director/lingo/lingo-preprocessor.cpp
index 5e63f30..a5a8385 100644
--- a/engines/director/lingo/lingo-preprocessor.cpp
+++ b/engines/director/lingo/lingo-preprocessor.cpp
@@ -26,7 +26,7 @@
namespace Director {
bool isspec(char c) {
- return strchr("-+*/%%^:,()><&[]", c) != NULL;
+ return strchr("-+*/%%^:,()><&[]=", c) != NULL;
}
static Common::String nexttok(const char *s, const char **newP = nullptr) {
@@ -59,8 +59,14 @@ static Common::String prevtok(const char *s, const char *lineStart, const char *
s--;
// Now copy everything till whitespace
- while (s >= lineStart && *s != ' ' && *s != '\t')
- res = *s-- + res;
+ if (Common::isAlnum(*s)) {
+ // Now copy everything till whitespace
+ while (s >= lineStart && (Common::isAlnum(*s) || *s == '.'))
+ res = *s-- + res;
+ } else {
+ while (s >= lineStart && isspec(*s))
+ res = *s-- + res;
+ }
if (newP)
*newP = s;
Commit: 88060db8e2ec3e7d8a055dba371528ee928a240f
https://github.com/scummvm/scummvm/commit/88060db8e2ec3e7d8a055dba371528ee928a240f
Author: Eugene Sandulenko (sev at scummvm.org)
Date: 2020-01-13T01:17:47+01:00
Commit Message:
DIRECTOR: LINGO: Added test for 'return' without spaces
Changed paths:
engines/director/lingo/tests/strings.lingo
diff --git a/engines/director/lingo/tests/strings.lingo b/engines/director/lingo/tests/strings.lingo
index 38f1e55..a591092 100644
--- a/engines/director/lingo/tests/strings.lingo
+++ b/engines/director/lingo/tests/strings.lingo
@@ -17,3 +17,5 @@ put "That is the last line of the file." & return & "Click Done to exit." && ret
if the key = Return then
dontPassEvent
end if
+
+when keydown then if the key=return then set the stagecolor to random (256)
More information about the Scummvm-git-logs
mailing list