summaryrefslogtreecommitdiff
path: root/tnslc/main.tnsl
diff options
context:
space:
mode:
Diffstat (limited to 'tnslc/main.tnsl')
-rw-r--r--tnslc/main.tnsl21
1 files changed, 18 insertions, 3 deletions
diff --git a/tnslc/main.tnsl b/tnslc/main.tnsl
index c7e8c95..cf2e8ac 100644
--- a/tnslc/main.tnsl
+++ b/tnslc/main.tnsl
@@ -1,15 +1,30 @@
:import "c_wrap_linux.tnsl"
:import "vector.tnsl"
-/; main [int]
+/; push_char(Vector` a, uint8 c)
+ a.push(~c)
+;/
+/; main [int]
Vector a
a.init(1)
-
+ push_char(~a, 'h')
+ push_char(~a, 'e')
+ push_char(~a, 'l')
+ push_char(~a, 'l')
+ push_char(~a, 'o')
+ push_char(~a, ' ')
+ push_char(~a, 'w')
+ push_char(~a, 'o')
+ push_char(~a, 'r')
+ push_char(~a, 'l')
+ push_char(~a, 'd')
+ push_char(~a, '\n')
+ push_char(~a, 0)
+ _printf(a.data)
a.end()
-
return 0
;/