about summary refs log tree commit diff
path: root/users/tazjin/rlox/examples
diff options
context:
space:
mode:
authorVincent Ambo <mail@tazj.in>2021-10-21T09·00+0200
committertazjin <mail@tazj.in>2021-10-22T09·42+0000
commit670662a360447509940dac417195cf419d7f42c5 (patch)
treed602009e12bac63309f60e2a4e271317bb6b17b4 /users/tazjin/rlox/examples
parentd57e43e1615ae28cfdc74c1c65cbe7863d782018 (diff)
feat(tazjin/rlox): Implement simple conditionals r/2986
... basically just optional blocks (no else).

Change-Id: If091c6b8fdeb6c13a5f3dd284d0a9a87f9f4228d
Reviewed-on: https://cl.tvl.fyi/c/depot/+/3739
Tested-by: BuildkiteCI
Reviewed-by: tazjin <mail@tazj.in>
Diffstat (limited to 'users/tazjin/rlox/examples')
-rw-r--r--users/tazjin/rlox/examples/if.lox5
1 files changed, 5 insertions, 0 deletions
diff --git a/users/tazjin/rlox/examples/if.lox b/users/tazjin/rlox/examples/if.lox
new file mode 100644
index 000000000000..b59f00b20161
--- /dev/null
+++ b/users/tazjin/rlox/examples/if.lox
@@ -0,0 +1,5 @@
+if (true) {
+  print "yes";
+}
+
+print "afterwards";