about summary refs log tree commit diff stats
path: root/html/061text.mu.html
diff options
context:
space:
mode:
authorKartik K. Agaram <vc@akkartik.com>2016-08-17 19:04:35 -0700
committerKartik K. Agaram <vc@akkartik.com>2016-08-17 19:04:35 -0700
commitd990e8f07aee36f68bcd270889d20c2d22b9aa0b (patch)
tree07a624ea81f2974e1bb038462f4d0607237ea431 /html/061text.mu.html
parentcb159b8c8a888f089676a63273b76b641e860d88 (diff)
downloadmu-d990e8f07aee36f68bcd270889d20c2d22b9aa0b.tar.gz
3219
Trying keeping html in the master branch:
  https://github.com/blog/2228-simpler-github-pages-publishing

Let's see if https://akkartik.github.io/mu updates after I push this
commit to just the master branch.
Diffstat (limited to 'html/061text.mu.html')
-rw-r--r--html/061text.mu.html14
1 files changed, 14 insertions, 0 deletions
diff --git a/html/061text.mu.html b/html/061text.mu.html
index 589ca78e..268d4275 100644
--- a/html/061text.mu.html
+++ b/html/061text.mu.html
@@ -156,6 +156,11 @@ body { font-size: 12pt; font-family: monospace; color: #eeeeee; background-color
   <span class="Constant">load-ingredients</span>
   result<span class="Special"> &lt;- </span>new <span class="Constant">buffer:type</span>
   *result<span class="Special"> &lt;- </span>put *result, <span class="Constant">length:offset</span>, <span class="Constant">0</span>
+  <span class="Delimiter">{</span>
+    <span class="muControl">break-if</span> capacity
+    <span class="Comment"># capacity not provided</span>
+    capacity<span class="Special"> &lt;- </span>copy <span class="Constant">10</span>
+  <span class="Delimiter">}</span>
   data:address:array:character<span class="Special"> &lt;- </span>new <span class="Constant">character:type</span>, capacity
   *result<span class="Special"> &lt;- </span>put *result, <span class="Constant">data:offset</span>, data
   <span class="muControl">return</span> result
@@ -276,6 +281,15 @@ body { font-size: 12pt; font-family: monospace; color: #eeeeee; background-color
   ]
 ]
 
+<span class="muScenario">scenario</span> buffer-append-to-empty [
+  run [
+    <span class="Constant">local-scope</span>
+    x:address:buffer<span class="Special"> &lt;- </span>new-buffer
+    c:character<span class="Special"> &lt;- </span>copy <span class="Constant">97/a</span>
+    x<span class="Special"> &lt;- </span>append x, c
+  ]
+]
+
 <span class="muScenario">scenario</span> buffer-append-handles-backspace [
   run [
     <span class="Constant">local-scope</span>