diff options
Diffstat (limited to 'html/088file.mu.html')
-rw-r--r-- | html/088file.mu.html | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/html/088file.mu.html b/html/088file.mu.html index 88c45143..f4b0be86 100644 --- a/html/088file.mu.html +++ b/html/088file.mu.html @@ -81,7 +81,7 @@ if ('onhashchange' in window) { <span id="L20" class="LineNr"> 20 </span> <span id="L21" class="LineNr"> 21 </span><span class="muRecipe">def</span> <a href='088file.mu.html#L21'>start-reading</a> <a href='088file.mu.html#L11'>resources</a>:&:<a href='088file.mu.html#L11'>resources</a>, filename:text<span class="muRecipe"> -> </span>contents:&:<a href='075channel.mu.html#L43'>source</a>:char, error?:bool [ <span id="L22" class="LineNr"> 22 </span> <span class="Constant">local-scope</span> -<span id="L23" class="LineNr"> 23 </span> <span class="Constant">load-ingredients</span> +<span id="L23" class="LineNr"> 23 </span> <span class="Constant">load-inputs</span> <span id="L24" class="LineNr"> 24 </span> error? <span class="Special"><-</span> copy <span class="Constant">0/false</span> <span id="L25" class="LineNr"> 25 </span> <span class="Delimiter">{</span> <span id="L26" class="LineNr"> 26 </span> <span class="Conceal">¦</span> <span class="muControl">break-unless</span> <a href='088file.mu.html#L11'>resources</a> @@ -98,7 +98,7 @@ if ('onhashchange' in window) { <span id="L37" class="LineNr"> 37 </span> <span id="L38" class="LineNr"> 38 </span><span class="muRecipe">def</span> <a href='088file.mu.html#L38'>slurp</a> <a href='088file.mu.html#L11'>resources</a>:&:<a href='088file.mu.html#L11'>resources</a>, filename:text<span class="muRecipe"> -> </span>contents:text, error?:bool [ <span id="L39" class="LineNr"> 39 </span> <span class="Constant">local-scope</span> -<span id="L40" class="LineNr"> 40 </span> <span class="Constant">load-ingredients</span> +<span id="L40" class="LineNr"> 40 </span> <span class="Constant">load-inputs</span> <span id="L41" class="LineNr"> 41 </span> <a href='075channel.mu.html#L43'>source</a>:&:<a href='075channel.mu.html#L43'>source</a>:char, error?:bool <span class="Special"><-</span> <a href='088file.mu.html#L21'>start-reading</a> <a href='088file.mu.html#L11'>resources</a>, filename <span id="L42" class="LineNr"> 42 </span> <span class="muControl">return-if</span> error?, <span class="Constant">0/contents</span> <span id="L43" class="LineNr"> 43 </span> buf:&:<a href='061text.mu.html#L120'>buffer</a>:char <span class="Special"><-</span> <a href='061text.mu.html#L125'>new-buffer</a> <span class="Constant">30/capacity</span> @@ -113,7 +113,7 @@ if ('onhashchange' in window) { <span id="L52" class="LineNr"> 52 </span> <span id="L53" class="LineNr"> 53 </span><span class="muRecipe">def</span> <a href='088file.mu.html#L53'>start-reading-from-fake-resource</a> <a href='088file.mu.html#L11'>resources</a>:&:<a href='088file.mu.html#L11'>resources</a>, <a href='088file.mu.html#L16'>resource</a>:text<span class="muRecipe"> -> </span>contents:&:<a href='075channel.mu.html#L43'>source</a>:char, error?:bool [ <span id="L54" class="LineNr"> 54 </span> <span class="Constant">local-scope</span> -<span id="L55" class="LineNr"> 55 </span> <span class="Constant">load-ingredients</span> +<span id="L55" class="LineNr"> 55 </span> <span class="Constant">load-inputs</span> <span id="L56" class="LineNr"> 56 </span> error? <span class="Special"><-</span> copy <span class="Constant">0/no-error</span> <span id="L57" class="LineNr"> 57 </span> i:num <span class="Special"><-</span> copy<span class="Constant"> 0</span> <span id="L58" class="LineNr"> 58 </span> data:&:@:<a href='088file.mu.html#L16'>resource</a> <span class="Special"><-</span> get *resources, <span class="Constant">data:offset</span> @@ -136,7 +136,7 @@ if ('onhashchange' in window) { <span id="L75" class="LineNr"> 75 </span> <span id="L76" class="LineNr"> 76 </span><span class="muRecipe">def</span> <a href='088file.mu.html#L76'>receive-from-file</a> file:num, <a href='075channel.mu.html#L47'>sink</a>:&:<a href='075channel.mu.html#L47'>sink</a>:char<span class="muRecipe"> -> </span><a href='075channel.mu.html#L47'>sink</a>:&:<a href='075channel.mu.html#L47'>sink</a>:char [ <span id="L77" class="LineNr"> 77 </span> <span class="Constant">local-scope</span> -<span id="L78" class="LineNr"> 78 </span> <span class="Constant">load-ingredients</span> +<span id="L78" class="LineNr"> 78 </span> <span class="Constant">load-inputs</span> <span id="L79" class="LineNr"> 79 </span> <span class="Delimiter">{</span> <span id="L80" class="LineNr"> 80 </span> <span class="Conceal">¦</span> c:char, eof?:bool <span class="Special"><-</span> $read-from-file file <span id="L81" class="LineNr"> 81 </span> <span class="Conceal">¦</span> <span class="muControl">break-if</span> eof? @@ -149,7 +149,7 @@ if ('onhashchange' in window) { <span id="L88" class="LineNr"> 88 </span> <span id="L89" class="LineNr"> 89 </span><span class="muRecipe">def</span> <a href='088file.mu.html#L89'>receive-from-text</a> contents:text, <a href='075channel.mu.html#L47'>sink</a>:&:<a href='075channel.mu.html#L47'>sink</a>:char<span class="muRecipe"> -> </span><a href='075channel.mu.html#L47'>sink</a>:&:<a href='075channel.mu.html#L47'>sink</a>:char [ <span id="L90" class="LineNr"> 90 </span> <span class="Constant">local-scope</span> -<span id="L91" class="LineNr"> 91 </span> <span class="Constant">load-ingredients</span> +<span id="L91" class="LineNr"> 91 </span> <span class="Constant">load-inputs</span> <span id="L92" class="LineNr"> 92 </span> i:num <span class="Special"><-</span> copy<span class="Constant"> 0</span> <span id="L93" class="LineNr"> 93 </span> len:num <span class="Special"><-</span> length *contents <span id="L94" class="LineNr"> 94 </span> <span class="Delimiter">{</span> @@ -165,7 +165,7 @@ if ('onhashchange' in window) { <span id="L104" class="LineNr">104 </span> <span id="L105" class="LineNr">105 </span><span class="muRecipe">def</span> <a href='088file.mu.html#L105'>start-writing</a> <a href='088file.mu.html#L11'>resources</a>:&:<a href='088file.mu.html#L11'>resources</a>, filename:text<span class="muRecipe"> -> </span><a href='075channel.mu.html#L47'>sink</a>:&:<a href='075channel.mu.html#L47'>sink</a>:char, routine-id:num, error?:bool [ <span id="L106" class="LineNr">106 </span> <span class="Constant">local-scope</span> -<span id="L107" class="LineNr">107 </span> <span class="Constant">load-ingredients</span> +<span id="L107" class="LineNr">107 </span> <span class="Constant">load-inputs</span> <span id="L108" class="LineNr">108 </span> error? <span class="Special"><-</span> copy <span class="Constant">0/false</span> <span id="L109" class="LineNr">109 </span> <a href='075channel.mu.html#L43'>source</a>:&:<a href='075channel.mu.html#L43'>source</a>:char, <a href='075channel.mu.html#L47'>sink</a>:&:<a href='075channel.mu.html#L47'>sink</a>:char <span class="Special"><-</span> <a href='075channel.mu.html#L51'>new-channel</a><span class="Constant"> 30</span> <span id="L110" class="LineNr">110 </span> <span class="Delimiter">{</span> @@ -187,7 +187,7 @@ if ('onhashchange' in window) { <span id="L126" class="LineNr">126 </span> <span id="L127" class="LineNr">127 </span><span class="muRecipe">def</span> <a href='088file.mu.html#L127'>dump</a> <a href='088file.mu.html#L11'>resources</a>:&:<a href='088file.mu.html#L11'>resources</a>, filename:text, contents:text<span class="muRecipe"> -> </span><a href='088file.mu.html#L11'>resources</a>:&:<a href='088file.mu.html#L11'>resources</a>, error?:bool [ <span id="L128" class="LineNr">128 </span> <span class="Constant">local-scope</span> -<span id="L129" class="LineNr">129 </span> <span class="Constant">load-ingredients</span> +<span id="L129" class="LineNr">129 </span> <span class="Constant">load-inputs</span> <span id="L130" class="LineNr">130 </span> <span class="Comment"># todo: really create an empty file</span> <span id="L131" class="LineNr">131 </span> <span class="muControl">return-unless</span> contents, <a href='088file.mu.html#L11'>resources</a>, <span class="Constant">0/no-error</span> <span id="L132" class="LineNr">132 </span> sink-file:&:<a href='075channel.mu.html#L47'>sink</a>:char, write-routine:num, error?:bool <span class="Special"><-</span> <a href='088file.mu.html#L105'>start-writing</a> <a href='088file.mu.html#L11'>resources</a>, filename @@ -210,7 +210,7 @@ if ('onhashchange' in window) { <span id="L149" class="LineNr">149 </span> <span id="L150" class="LineNr">150 </span><span class="muRecipe">def</span> <a href='088file.mu.html#L150'>transmit-to-file</a> file:num, <a href='075channel.mu.html#L43'>source</a>:&:<a href='075channel.mu.html#L43'>source</a>:char<span class="muRecipe"> -> </span><a href='075channel.mu.html#L43'>source</a>:&:<a href='075channel.mu.html#L43'>source</a>:char [ <span id="L151" class="LineNr">151 </span> <span class="Constant">local-scope</span> -<span id="L152" class="LineNr">152 </span> <span class="Constant">load-ingredients</span> +<span id="L152" class="LineNr">152 </span> <span class="Constant">load-inputs</span> <span id="L153" class="LineNr">153 </span> <span class="Delimiter">{</span> <span id="L154" class="LineNr">154 </span> <span class="Conceal">¦</span> c:char, done?:bool, <a href='075channel.mu.html#L43'>source</a> <span class="Special"><-</span> read <a href='075channel.mu.html#L43'>source</a> <span id="L155" class="LineNr">155 </span> <span class="Conceal">¦</span> <span class="muControl">break-if</span> done? @@ -222,7 +222,7 @@ if ('onhashchange' in window) { <span id="L161" class="LineNr">161 </span> <span id="L162" class="LineNr">162 </span><span class="muRecipe">def</span> <a href='088file.mu.html#L162'>transmit-to-fake-resource</a> <a href='088file.mu.html#L11'>resources</a>:&:<a href='088file.mu.html#L11'>resources</a>, filename:text, <a href='075channel.mu.html#L43'>source</a>:&:<a href='075channel.mu.html#L43'>source</a>:char<span class="muRecipe"> -> </span><a href='088file.mu.html#L11'>resources</a>:&:<a href='088file.mu.html#L11'>resources</a>, <a href='075channel.mu.html#L43'>source</a>:&:<a href='075channel.mu.html#L43'>source</a>:char [ <span id="L163" class="LineNr">163 </span> <span class="Constant">local-scope</span> -<span id="L164" class="LineNr">164 </span> <span class="Constant">load-ingredients</span> +<span id="L164" class="LineNr">164 </span> <span class="Constant">load-inputs</span> <span id="L165" class="LineNr">165 </span> lock:location <span class="Special"><-</span> get-location *resources, <span class="Constant">lock:offset</span> <span id="L166" class="LineNr">166 </span> wait-for-reset-then-set lock <span id="L167" class="LineNr">167 </span> <span class="Comment"># compute new file contents</span> |