summaryrefslogtreecommitdiff
path: root/test.toc
diff options
context:
space:
mode:
authorLeo Tenenbaum <pommicket@gmail.com>2020-07-15 17:06:01 -0400
committerLeo Tenenbaum <pommicket@gmail.com>2020-07-15 17:06:01 -0400
commit0cf4c0567399f597e2d3a5a9e0612c7ce69d9992 (patch)
tree912814e5d71e67a52612960ffd7f6204edd3835d /test.toc
parentd7d3e9ed8a6f6c2a116fb82ac3c891d3cae0a482 (diff)
only allow using a struct after its declared (except for inside other structs)HEADtrunk
Diffstat (limited to 'test.toc')
-rw-r--r--test.toc8
1 files changed, 4 insertions, 4 deletions
diff --git a/test.toc b/test.toc
index a47bab6..d4064de 100644
--- a/test.toc
+++ b/test.toc
@@ -1,12 +1,12 @@
+#include "std/io.toc";
+a ::= struct {
+ foo: File;
+}
main ::= fn() {
x: &a;
k := x.foo;
}
main();
-#include "std/io.toc";
-a ::= struct {
- foo: File;
-}
/*