Get all for loop related unit tests passing and expand the types of expressions

that can exist in a for loop
This commit is contained in:
Jason Turner
2013-02-23 21:14:37 -07:00
parent c9995480e6
commit 48f538438d
4 changed files with 54 additions and 13 deletions

View File

@@ -40,9 +40,9 @@ for (;;l = 1)
assert_equal(0, l)
def isTrue(x)
def isNotFive(x)
{
if (x == 5)
if (x != 5)
{
return true
} else {
@@ -50,7 +50,9 @@ def isTrue(x)
}
}
for (var m = 0; isTrue(m); m = m + 1)
var m;
for (m = 0; isNotFive(m); m = m + 1)
{
}