Added indexing to strings, tests still needed

This commit is contained in:
2024-11-09 13:06:48 +11:00
parent 5588986042
commit 1925d41940
8 changed files with 229 additions and 42 deletions

View File

@@ -13,6 +13,11 @@ print "Hello" .. "world!";
//print with escaped characters
print "\tHello\nworld";
//print from a leaf string
print "Hello world"[0,5];
print ("hello" .. "world")[2,6];
//TODO: in the repl, -s to supress output, or -d to print debugging info
//TODO: the `assert` keyword will be useful for these