about summary refs log tree commit diff stats
path: root/tutorial/task8b.mu
diff options
context:
space:
mode:
authorKartik K. Agaram <vc@akkartik.com>2021-10-26 23:12:57 -0700
committerKartik K. Agaram <vc@akkartik.com>2021-10-26 23:14:36 -0700
commitc7dde8d8b4338d478fc61c4a8ea5e1c84bf5513e (patch)
tree62a083cd61861ea57568986682d75f941d4972a0 /tutorial/task8b.mu
parent5713eb7302a11af489faeb3172cc376398db57e0 (diff)
downloadmu-c7dde8d8b4338d478fc61c4a8ea5e1c84bf5513e.tar.gz
task: primitive statements vs function calls
Diffstat (limited to 'tutorial/task8b.mu')
-rw-r--r--tutorial/task8b.mu8
1 files changed, 8 insertions, 0 deletions
diff --git a/tutorial/task8b.mu b/tutorial/task8b.mu
new file mode 100644
index 00000000..888f01ec
--- /dev/null
+++ b/tutorial/task8b.mu
@@ -0,0 +1,8 @@
+fn f -> _/eax: int {
+  var result/ecx: int <- copy 0
+  return result
+}
+
+fn main {
+  var x/eax: int <- f
+}