From cdf2822743b3beeb37ebc3deea8e08b6130698c5 Mon Sep 17 00:00:00 2001 From: Kartik Agaram Date: Sat, 12 May 2018 10:22:26 -0700 Subject: 4242 - get rid of refcounts entirely We're going to lean back into the experiment of commit 4179 back in Jan. If we delete memory it's up to us to ensure no pointers into it survive. Since deep-copy depends on our refcounting infrastructure, it's gone as well. So we're going to have to start watching out for pointers shared over channels. --- html/061text.mu.html | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'html/061text.mu.html') diff --git a/html/061text.mu.html b/html/061text.mu.html index 1cf8aa34..d069e621 100644 --- a/html/061text.mu.html +++ b/html/061text.mu.html @@ -183,17 +183,17 @@ if ('onhashchange' in window) { 122 data:&:@:_elem 123 ] 124 - 125 def new-buffer capacity:num -> result:&:buffer:_elem [ + 125 def new-buffer capacity:num -> result:&:buffer:_elem [ 126 local-scope 127 load-inputs 128 result <- new {(buffer _elem): type} 129 *result <- put *result, length:offset, 0 130 { - 131 break-if capacity + 131 break-if capacity 132 # capacity not provided - 133 capacity <- copy 10 + 133 capacity <- copy 10 134 } - 135 data:&:@:_elem <- new _elem:type, capacity + 135 data:&:@:_elem <- new _elem:type, capacity 136 *result <- put *result, data:offset, data 137 return result 138 ] @@ -224,8 +224,8 @@ if ('onhashchange' in window) { 163 load-inputs 164 len:num <- get *in, length:offset 165 s:&:@:_elem <- get *in, data:offset - 166 capacity:num <- length *s - 167 result <- greater-or-equal len, capacity + 166 capacity:num <- length *s + 167 result <- greater-or-equal len, capacity 168 ] 169 170 # most broadly applicable definition of append to a buffer -- cgit 1.4.1-2-gfad0