summaryrefslogtreecommitdiff
path: root/test.toc
diff options
context:
space:
mode:
Diffstat (limited to 'test.toc')
-rw-r--r--test.toc9
1 files changed, 8 insertions, 1 deletions
diff --git a/test.toc b/test.toc
index d4726ff..f7db673 100644
--- a/test.toc
+++ b/test.toc
@@ -1,5 +1,5 @@
Foo ::= struct {
- x: u8;
+ x: int;
};
#export main ::= fn() Foo {
g ::= fn() int { 3 };
@@ -7,5 +7,12 @@ Foo ::= struct {
b := a[1:3];
b[0] = 7;
f: Foo;
+ each i, j := b {
+ f.x += i + j;
+ }
+ each k := 10..100 {
+ f.x += k;
+ }
+
f
}; \ No newline at end of file