about summary refs log tree commit diff stats
path: root/mu.arc.t
diff options
context:
space:
mode:
authorKartik K. Agaram <vc@akkartik.com>2014-11-01 16:34:33 -0700
committerKartik K. Agaram <vc@akkartik.com>2014-11-01 16:34:33 -0700
commit002cbf13f181626ff5bc71f4d7269637ea0fdfea (patch)
treea1e99a25a2597894873b8e209e2101c7d7b0438a /mu.arc.t
parent2c9aa92f56c6f4051216774e9d10f795dd12bf0d (diff)
downloadmu-002cbf13f181626ff5bc71f4d7269637ea0fdfea.tar.gz
213 - bring back the fork example
Diffstat (limited to 'mu.arc.t')
-rw-r--r--mu.arc.t12
1 files changed, 12 insertions, 0 deletions
diff --git a/mu.arc.t b/mu.arc.t
index 4fdabb56..002ecbcf 100644
--- a/mu.arc.t
+++ b/mu.arc.t
@@ -1286,6 +1286,18 @@
             ((nil integer) <- add (1 integer) (2 integer))))
   (prn "F - convert-names never renames nil"))
 
+; kludgy support for 'fork'
+(reset)
+(new-trace "convert-names-functions")
+(if (~iso (convert-names
+            '(((x integer) <- copy (4 literal))
+              ((y integer) <- copy (2 literal))
+              ((z fn) <- add (x integer) (y integer))))
+          '(((1 integer) <- copy (4 literal))
+            ((2 integer) <- copy (2 literal))
+            ((z fn) <- add (1 integer) (2 integer))))
+  (prn "F - convert-names never renames nil"))
+
 ; A rudimentary memory allocator. Eventually we want to write this in mu.
 ;
 ; No deallocation yet; let's see how much code we can build in mu before we