diff options
Diffstat (limited to 'test.toc')
-rw-r--r-- | test.toc | 15 |
1 files changed, 8 insertions, 7 deletions
@@ -2,8 +2,8 @@ g ::= fn(modulator: int, x : ..) int { total := 0; - for e, i := x { - total += modulator * i * (e as int); + for e := x { + total += modulator * (e as int); } total }; @@ -13,14 +13,15 @@ f ::= fn(x : ..) int { }; main ::= fn() { - puti(f(5)); + puti(f(5)); - puti(f(5,6)); + puti(f(5,6)); - puti(f(1,2,3)); - - puti(f(1,1,1,1)); + puti(f(1,2,3)); + puti(f(1,1,1,1)); + + puti(f()); }; main();
\ No newline at end of file |