aboutsummaryrefslogtreecommitdiff
path: root/examples/learn/29-block-comments.zc
diff options
context:
space:
mode:
Diffstat (limited to 'examples/learn/29-block-comments.zc')
-rw-r--r--examples/learn/29-block-comments.zc11
1 files changed, 11 insertions, 0 deletions
diff --git a/examples/learn/29-block-comments.zc b/examples/learn/29-block-comments.zc
new file mode 100644
index 0000000..a5088eb
--- /dev/null
+++ b/examples/learn/29-block-comments.zc
@@ -0,0 +1,11 @@
+namespace;
+include rt;
+
+/* adds a memory offset to an address. */
+int offset_address(int address) {
+ return address + /* offset in memory */ 0x40ff;
+}
+
+fn main() {
+ rt.put_n(offset_address(1)); rt.put_c(10);
+}