about summary refs log tree commit diff
path: root/examples
diff options
context:
space:
mode:
authorBaitinq <[email protected]>2025-03-14 00:51:00 +0100
committerBaitinq <[email protected]>2025-03-14 00:51:00 +0100
commit73ad747d98e0440837738e7a87ad1e4c730b0a6f (patch)
treea0582ec0e95d1b0ca80b25005331f892f9796c16 /examples
parentCodegen: Fix printing of llvm error messages (diff)
downloadinterpreter-73ad747d98e0440837738e7a87ad1e4c730b0a6f.tar.gz
interpreter-73ad747d98e0440837738e7a87ad1e4c730b0a6f.tar.bz2
interpreter-73ad747d98e0440837738e7a87ad1e4c730b0a6f.zip
Examples: Add new function as return example
Diffstat (limited to 'examples')
-rw-r--r--examples/14.src11
1 files changed, 11 insertions, 0 deletions
diff --git a/examples/14.src b/examples/14.src
new file mode 100644
index 0000000..88b898e
--- /dev/null
+++ b/examples/14.src
@@ -0,0 +1,11 @@
+let main = () => i64 {
+	let fn = () => () => i64 {
+		return () => i64 {
+			return 4;
+		};
+	};
+
+	let x = fn();
+
+	return x();
+};