about summary refs log tree commit diff stats
path: root/065duplex_list.mu
diff options
context:
space:
mode:
authorKartik K. Agaram <vc@akkartik.com>2015-07-13 22:43:16 -0700
committerKartik K. Agaram <vc@akkartik.com>2015-07-13 22:50:49 -0700
commit77d5b5d658830bd24724f945e0d6ddf6a06adc0e (patch)
tree94c50c0ddfa6d55dc1189d62243ceeacaf783326 /065duplex_list.mu
parent84e4ed1ab58d5b34cf92919aedbb15736a7349d9 (diff)
downloadmu-77d5b5d658830bd24724f945e0d6ddf6a06adc0e.tar.gz
1780 - now we always reclaim local scopes
But still no difference in either memory footprint or in running time.
This will teach me -- for the umpteenth time -- to optimize before
measuring.
Diffstat (limited to '065duplex_list.mu')
-rw-r--r--065duplex_list.mu12
1 files changed, 6 insertions, 6 deletions
diff --git a/065duplex_list.mu b/065duplex_list.mu
index 02e1462d..c54934ec 100644
--- a/065duplex_list.mu
+++ b/065duplex_list.mu
@@ -8,7 +8,7 @@ container duplex-list [
 
 # result:address:duplex-list <- push-duplex x:location, in:address:duplex-list
 recipe push-duplex [
-  new-default-space
+  local-scope
   x:location <- next-ingredient
   in:address:duplex-list <- next-ingredient
   result:address:duplex-list <- new duplex-list:type
@@ -24,7 +24,7 @@ recipe push-duplex [
 
 # result:location <- first-duplex in:address:duplex-list
 recipe first-duplex [
-  new-default-space
+  local-scope
   in:address:duplex-list <- next-ingredient
   reply-unless in:address:duplex-list, 0:literal
   result:location <- get in:address:duplex-list/deref, value:offset
@@ -33,7 +33,7 @@ recipe first-duplex [
 
 # result:address:duplex-list <- next-duplex in:address:duplex-list
 recipe next-duplex [
-  new-default-space
+  local-scope
   in:address:duplex-list <- next-ingredient
   reply-unless in:address:duplex-list, 0:literal
   result:address:duplex-list <- get in:address:duplex-list/deref, next:offset
@@ -42,7 +42,7 @@ recipe next-duplex [
 
 # result:address:duplex-list <- prev-duplex in:address:duplex-list
 recipe prev-duplex [
-  new-default-space
+  local-scope
   in:address:duplex-list <- next-ingredient
   reply-unless in:address:duplex-list, 0:literal
   result:address:duplex-list <- get in:address:duplex-list/deref, prev:offset
@@ -95,7 +95,7 @@ scenario duplex-list-handling [
 # l:address:duplex-list <- insert-duplex x:location, in:address:duplex-list
 # Inserts 'x' after 'in'. Returns some pointer into the list.
 recipe insert-duplex [
-  new-default-space
+  local-scope
   x:location <- next-ingredient
   in:address:duplex-list <- next-ingredient
   new-node:address:duplex-list <- new duplex-list:type
@@ -237,7 +237,7 @@ scenario inserting-after-start-of-duplex-list [
 # Returns null if and only if list is empty. Beware: in that case any pointers
 # to the head are now invalid.
 recipe remove-duplex [
-  new-default-space
+  local-scope
   in:address:duplex-list <- next-ingredient
   # if 'in' is null, return
   reply-unless in:address:duplex-list, in:address:duplex-list