From 83fcebf3210b638d9f8248e0007e9f0c9804980a Mon Sep 17 00:00:00 2001 From: "Kartik K. Agaram" Date: Mon, 13 Jul 2015 20:53:41 -0700 Subject: 1778 --- html/061channel.mu.html | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) (limited to 'html/061channel.mu.html') diff --git a/html/061channel.mu.html b/html/061channel.mu.html index 009ae701..d1fc9b9b 100644 --- a/html/061channel.mu.html +++ b/html/061channel.mu.html @@ -15,13 +15,13 @@ body { font-family: monospace; color: #eeeeee; background-color: #080808; } * { font-size: 1.05em; } .muScenario { color: #00af00; } .Delimiter { color: #a04060; } +.muRecipe { color: #ff8700; } .SalientComment { color: #00ffff; } .Comment { color: #9090ff; } .Constant { color: #00a0a0; } .Special { color: #ff6060; } .CommentedCode { color: #6c6c6c; } .muControl { color: #c0a020; } -.muRecipe { color: #ff8700; } --> @@ -68,7 +68,7 @@ container channel [ # result:address:channel <- new-channel capacity:number recipe new-channel [ - default-space:address:array:location <- new location:type, 30:literal + new-default-space # result = new channel result:address:channel <- new channel:type # result.first-full = 0 @@ -87,7 +87,7 @@ container channel [ # chan:address:channel <- write chan:address:channel, val:location recipe write [ - default-space:address:array:location <- new location:type, 30:literal + new-default-space chan:address:channel <- next-ingredient val:location <- next-ingredient { @@ -116,7 +116,7 @@ container channel [ # result:location, chan:address:channel <- read chan:address:channel recipe read [ - default-space:address:array:location <- new location:type, 30:literal + new-default-space chan:address:channel <- next-ingredient { # block if chan is empty @@ -142,7 +142,7 @@ container channel [ ] recipe clear-channel [ - default-space:address:address:array:location <- new location:type, 30:literal + new-default-space chan:address:channel <- next-ingredient { empty?:boolean <- channel-empty? chan:address:channel @@ -220,7 +220,7 @@ container channel [ # An empty channel has first-empty and first-full both at the same value. recipe channel-empty? [ - default-space:address:array:location <- new location:type, 30:literal + new-default-space chan:address:channel <- next-ingredient # return chan.first-full == chan.first-free full:number <- get chan:address:channel/deref, first-full:offset @@ -232,7 +232,7 @@ container channel [ # A full channel has first-empty just before first-full, wasting one slot. # (Other alternatives: https://en.wikipedia.org/wiki/Circular_buffer#Full_.2F_Empty_Buffer_Distinction) recipe channel-full? [ - default-space:address:array:location <- new location:type, 30:literal + new-default-space chan:address:channel <- next-ingredient # tmp = chan.first-free + 1 tmp:number <- get chan:address:channel/deref, first-free:offset @@ -252,7 +252,7 @@ container channel [ # result:number <- channel-capacity chan:address:channel recipe channel-capacity [ - default-space:address:array:location <- new location:type, 30:literal + new-default-space chan:address:channel <- next-ingredient q:address:array:location <- get chan:address:channel/deref, data:offset result:number <- length q:address:array:location/deref @@ -314,7 +314,7 @@ container channel [ # helper for channels of characters in particular # out:address:channel <- buffer-lines in:address:channel, out:address:channel recipe buffer-lines [ - default-space:address:address:array:location <- new location:type, 30:literal + new-default-space #? $print [buffer-lines: aaa #? ] in:address:channel <- next-ingredient -- cgit 1.4.1-2-gfad0