diff options
author | Kartik Agaram <vc@akkartik.com> | 2021-04-22 20:02:19 -0700 |
---|---|---|
committer | Kartik Agaram <vc@akkartik.com> | 2021-04-22 20:02:19 -0700 |
commit | 59151049263ce58a8c80c26d188c0852bb285b82 (patch) | |
tree | 14558f878e5ca5222823ed6ffdaa3791d6a259ed /html/shell/tokenize.mu.html | |
parent | 2ff86d91628328793e584d9980748ea1c917ad57 (diff) | |
download | mu-59151049263ce58a8c80c26d188c0852bb285b82.tar.gz |
.
Diffstat (limited to 'html/shell/tokenize.mu.html')
-rw-r--r-- | html/shell/tokenize.mu.html | 42 |
1 files changed, 21 insertions, 21 deletions
diff --git a/html/shell/tokenize.mu.html b/html/shell/tokenize.mu.html index 643a01c0..7eae1112 100644 --- a/html/shell/tokenize.mu.html +++ b/html/shell/tokenize.mu.html @@ -62,8 +62,8 @@ if ('onhashchange' in window) { <span id="L3" class="LineNr"> 3 </span><span class="muComment"># they always have text-data.</span> <span id="L4" class="LineNr"> 4 </span> <span id="L5" class="LineNr"> 5 </span><span class="PreProc">fn</span> <span class="muFunction"><a href='tokenize.mu.html#L5'>tokenize</a></span> in: (addr <a href='gap-buffer.mu.html#L3'>gap-buffer</a>), out: (addr stream <a href='cell.mu.html#L1'>cell</a>), trace: (addr trace) <span class="Delimiter">{</span> -<span id="L6" class="LineNr"> 6 </span> <a href='trace.mu.html#L113'>trace-text</a> trace, <span class="Constant">"read"</span>, <span class="Constant">"tokenize"</span> -<span id="L7" class="LineNr"> 7 </span> <a href='trace.mu.html#L140'>trace-lower</a> trace +<span id="L6" class="LineNr"> 6 </span> <a href='trace.mu.html#L120'>trace-text</a> trace, <span class="Constant">"read"</span>, <span class="Constant">"tokenize"</span> +<span id="L7" class="LineNr"> 7 </span> <a href='trace.mu.html#L147'>trace-lower</a> trace <span id="L8" class="LineNr"> 8 </span> <a href='gap-buffer.mu.html#L740'>rewind-gap-buffer</a> in <span id="L9" class="LineNr"> 9 </span> <span class="PreProc">var</span> token-storage: <a href='cell.mu.html#L1'>cell</a> <span id="L10" class="LineNr"> 10 </span> <span class="PreProc">var</span> token/<span class="Constant">edx</span>: (addr <a href='cell.mu.html#L1'>cell</a>) <span class="Special"><-</span> address token-storage @@ -86,7 +86,7 @@ if ('onhashchange' in window) { <span id="L27" class="LineNr"> 27 </span> <a href='../309stream.subx.html#L54'>write-to-stream</a> out, token <span class="muComment"># shallow-copy text-data</span> <span id="L28" class="LineNr"> 28 </span> <span class="PreProc">loop</span> <span id="L29" class="LineNr"> 29 </span> <span class="Delimiter">}</span> -<span id="L30" class="LineNr"> 30 </span> <a href='trace.mu.html#L148'>trace-higher</a> trace +<span id="L30" class="LineNr"> 30 </span> <a href='trace.mu.html#L155'>trace-higher</a> trace <span id="L31" class="LineNr"> 31 </span><span class="Delimiter">}</span> <span id="L32" class="LineNr"> 32 </span> <span id="L33" class="LineNr"> 33 </span><span class="PreProc">fn</span> <span class="muTest"><a href='tokenize.mu.html#L33'>test-tokenize-dotted-list</a></span> <span class="Delimiter">{</span> @@ -123,8 +123,8 @@ if ('onhashchange' in window) { <span id="L64" class="LineNr"> 64 </span><span class="Delimiter">}</span> <span id="L65" class="LineNr"> 65 </span> <span id="L66" class="LineNr"> 66 </span><span class="PreProc">fn</span> <span class="muFunction"><a href='tokenize.mu.html#L66'>next-token</a></span> in: (addr <a href='gap-buffer.mu.html#L3'>gap-buffer</a>), _out-cell: (addr <a href='cell.mu.html#L1'>cell</a>), trace: (addr trace) <span class="Delimiter">{</span> -<span id="L67" class="LineNr"> 67 </span> <a href='trace.mu.html#L113'>trace-text</a> trace, <span class="Constant">"read"</span>, <span class="Constant">"next-token"</span> -<span id="L68" class="LineNr"> 68 </span> <a href='trace.mu.html#L140'>trace-lower</a> trace +<span id="L67" class="LineNr"> 67 </span> <a href='trace.mu.html#L120'>trace-text</a> trace, <span class="Constant">"read"</span>, <span class="Constant">"next-token"</span> +<span id="L68" class="LineNr"> 68 </span> <a href='trace.mu.html#L147'>trace-lower</a> trace <span id="L69" class="LineNr"> 69 </span> <span class="PreProc">var</span> out-cell/<span class="Constant">eax</span>: (addr <a href='cell.mu.html#L1'>cell</a>) <span class="Special"><-</span> copy _out-cell <span id="L70" class="LineNr"> 70 </span> <span class="PreProc">var</span> out-ah/<span class="Constant">eax</span>: (addr handle stream byte) <span class="Special"><-</span> get out-cell, text-data <span id="L71" class="LineNr"> 71 </span> <span class="PreProc">var</span> _out/<span class="Constant">eax</span>: (addr stream byte) <span class="Special"><-</span> <a href='../120allocate.subx.html#L226'>lookup</a> *out-ah @@ -175,7 +175,7 @@ if ('onhashchange' in window) { <span id="L116" class="LineNr">116 </span> <span class="PreProc">break</span> $next-token:body <span id="L117" class="LineNr">117 </span> <span class="Delimiter">}</span> <span id="L118" class="LineNr">118 </span> <span class="Delimiter">}</span> -<span id="L119" class="LineNr">119 </span> <a href='trace.mu.html#L148'>trace-higher</a> trace +<span id="L119" class="LineNr">119 </span> <a href='trace.mu.html#L155'>trace-higher</a> trace <span id="L120" class="LineNr">120 </span> <span class="PreProc">var</span> stream-storage: (stream byte <span class="Constant">0x40</span>) <span id="L121" class="LineNr">121 </span> <span class="PreProc">var</span> stream/<span class="Constant">eax</span>: (addr stream byte) <span class="Special"><-</span> address stream-storage <span id="L122" class="LineNr">122 </span> <a href='../108write.subx.html#L11'>write</a> stream, <span class="Constant">"=> "</span> @@ -185,8 +185,8 @@ if ('onhashchange' in window) { <span id="L126" class="LineNr">126 </span><span class="Delimiter">}</span> <span id="L127" class="LineNr">127 </span> <span id="L128" class="LineNr">128 </span><span class="PreProc">fn</span> <span class="muFunction"><a href='tokenize.mu.html#L128'>next-symbol-token</a></span> in: (addr <a href='gap-buffer.mu.html#L3'>gap-buffer</a>), out: (addr stream byte), trace: (addr trace) <span class="Delimiter">{</span> -<span id="L129" class="LineNr">129 </span> <a href='trace.mu.html#L113'>trace-text</a> trace, <span class="Constant">"read"</span>, <span class="Constant">"looking for a symbol"</span> -<span id="L130" class="LineNr">130 </span> <a href='trace.mu.html#L140'>trace-lower</a> trace +<span id="L129" class="LineNr">129 </span> <a href='trace.mu.html#L120'>trace-text</a> trace, <span class="Constant">"read"</span>, <span class="Constant">"looking for a symbol"</span> +<span id="L130" class="LineNr">130 </span> <a href='trace.mu.html#L147'>trace-lower</a> trace <span id="L131" class="LineNr">131 </span> $next-symbol-token:<span class="PreProc">loop</span>: <span class="Delimiter">{</span> <span id="L132" class="LineNr">132 </span> <span class="PreProc">var</span> done?/<span class="Constant">eax</span>: boolean <span class="Special"><-</span> <a href='gap-buffer.mu.html#L748'>gap-buffer-scan-done?</a> in <span id="L133" class="LineNr">133 </span> compare done?, <span class="Constant">0</span>/false @@ -205,14 +205,14 @@ if ('onhashchange' in window) { <span id="L146" class="LineNr">146 </span> <span class="PreProc">var</span> <a href='tokenize.mu.html#L253'>symbol-grapheme?</a>/<span class="Constant">eax</span>: boolean <span class="Special"><-</span> <a href='tokenize.mu.html#L253'>symbol-grapheme?</a> g <span id="L147" class="LineNr">147 </span> compare <a href='tokenize.mu.html#L253'>symbol-grapheme?</a>, <span class="Constant">0</span>/false <span id="L148" class="LineNr">148 </span> <span class="PreProc">break-if-!=</span> -<span id="L149" class="LineNr">149 </span> <a href='trace.mu.html#L113'>trace-text</a> trace, <span class="Constant">"read"</span>, <span class="Constant">"stop"</span> +<span id="L149" class="LineNr">149 </span> <a href='trace.mu.html#L120'>trace-text</a> trace, <span class="Constant">"read"</span>, <span class="Constant">"stop"</span> <span id="L150" class="LineNr">150 </span> <span class="PreProc">break</span> $next-symbol-token:<span class="PreProc">loop</span> <span id="L151" class="LineNr">151 </span> <span class="Delimiter">}</span> <span id="L152" class="LineNr">152 </span> <span class="PreProc">var</span> g/<span class="Constant">eax</span>: grapheme <span class="Special"><-</span> <a href='gap-buffer.mu.html#L808'>read-from-gap-buffer</a> in <span id="L153" class="LineNr">153 </span> <a href='../403unicode.mu.html#L176'>write-grapheme</a> out, g <span id="L154" class="LineNr">154 </span> <span class="PreProc">loop</span> <span id="L155" class="LineNr">155 </span> <span class="Delimiter">}</span> -<span id="L156" class="LineNr">156 </span> <a href='trace.mu.html#L148'>trace-higher</a> trace +<span id="L156" class="LineNr">156 </span> <a href='trace.mu.html#L155'>trace-higher</a> trace <span id="L157" class="LineNr">157 </span> <span class="PreProc">var</span> stream-storage: (stream byte <span class="Constant">0x40</span>) <span id="L158" class="LineNr">158 </span> <span class="PreProc">var</span> stream/<span class="Constant">esi</span>: (addr stream byte) <span class="Special"><-</span> address stream-storage <span id="L159" class="LineNr">159 </span> <a href='../108write.subx.html#L11'>write</a> stream, <span class="Constant">"=> "</span> @@ -222,8 +222,8 @@ if ('onhashchange' in window) { <span id="L163" class="LineNr">163 </span><span class="Delimiter">}</span> <span id="L164" class="LineNr">164 </span> <span id="L165" class="LineNr">165 </span><span class="PreProc">fn</span> <span class="muFunction"><a href='tokenize.mu.html#L165'>next-operator-token</a></span> in: (addr <a href='gap-buffer.mu.html#L3'>gap-buffer</a>), out: (addr stream byte), trace: (addr trace) <span class="Delimiter">{</span> -<span id="L166" class="LineNr">166 </span> <a href='trace.mu.html#L113'>trace-text</a> trace, <span class="Constant">"read"</span>, <span class="Constant">"looking for a operator"</span> -<span id="L167" class="LineNr">167 </span> <a href='trace.mu.html#L140'>trace-lower</a> trace +<span id="L166" class="LineNr">166 </span> <a href='trace.mu.html#L120'>trace-text</a> trace, <span class="Constant">"read"</span>, <span class="Constant">"looking for a operator"</span> +<span id="L167" class="LineNr">167 </span> <a href='trace.mu.html#L147'>trace-lower</a> trace <span id="L168" class="LineNr">168 </span> $next-operator-token:<span class="PreProc">loop</span>: <span class="Delimiter">{</span> <span id="L169" class="LineNr">169 </span> <span class="PreProc">var</span> done?/<span class="Constant">eax</span>: boolean <span class="Special"><-</span> <a href='gap-buffer.mu.html#L748'>gap-buffer-scan-done?</a> in <span id="L170" class="LineNr">170 </span> compare done?, <span class="Constant">0</span>/false @@ -242,14 +242,14 @@ if ('onhashchange' in window) { <span id="L183" class="LineNr">183 </span> <span class="PreProc">var</span> <a href='tokenize.mu.html#L454'>operator-grapheme?</a>/<span class="Constant">eax</span>: boolean <span class="Special"><-</span> <a href='tokenize.mu.html#L454'>operator-grapheme?</a> g <span id="L184" class="LineNr">184 </span> compare <a href='tokenize.mu.html#L454'>operator-grapheme?</a>, <span class="Constant">0</span>/false <span id="L185" class="LineNr">185 </span> <span class="PreProc">break-if-!=</span> -<span id="L186" class="LineNr">186 </span> <a href='trace.mu.html#L113'>trace-text</a> trace, <span class="Constant">"read"</span>, <span class="Constant">"stop"</span> +<span id="L186" class="LineNr">186 </span> <a href='trace.mu.html#L120'>trace-text</a> trace, <span class="Constant">"read"</span>, <span class="Constant">"stop"</span> <span id="L187" class="LineNr">187 </span> <span class="PreProc">break</span> $next-operator-token:<span class="PreProc">loop</span> <span id="L188" class="LineNr">188 </span> <span class="Delimiter">}</span> <span id="L189" class="LineNr">189 </span> <span class="PreProc">var</span> g/<span class="Constant">eax</span>: grapheme <span class="Special"><-</span> <a href='gap-buffer.mu.html#L808'>read-from-gap-buffer</a> in <span id="L190" class="LineNr">190 </span> <a href='../403unicode.mu.html#L176'>write-grapheme</a> out, g <span id="L191" class="LineNr">191 </span> <span class="PreProc">loop</span> <span id="L192" class="LineNr">192 </span> <span class="Delimiter">}</span> -<span id="L193" class="LineNr">193 </span> <a href='trace.mu.html#L148'>trace-higher</a> trace +<span id="L193" class="LineNr">193 </span> <a href='trace.mu.html#L155'>trace-higher</a> trace <span id="L194" class="LineNr">194 </span> <span class="PreProc">var</span> stream-storage: (stream byte <span class="Constant">0x40</span>) <span id="L195" class="LineNr">195 </span> <span class="PreProc">var</span> stream/<span class="Constant">esi</span>: (addr stream byte) <span class="Special"><-</span> address stream-storage <span id="L196" class="LineNr">196 </span> <a href='../108write.subx.html#L11'>write</a> stream, <span class="Constant">"=> "</span> @@ -259,8 +259,8 @@ if ('onhashchange' in window) { <span id="L200" class="LineNr">200 </span><span class="Delimiter">}</span> <span id="L201" class="LineNr">201 </span> <span id="L202" class="LineNr">202 </span><span class="PreProc">fn</span> <span class="muFunction"><a href='tokenize.mu.html#L202'>next-number-token</a></span> in: (addr <a href='gap-buffer.mu.html#L3'>gap-buffer</a>), out: (addr stream byte), trace: (addr trace) <span class="Delimiter">{</span> -<span id="L203" class="LineNr">203 </span> <a href='trace.mu.html#L113'>trace-text</a> trace, <span class="Constant">"read"</span>, <span class="Constant">"looking for a number"</span> -<span id="L204" class="LineNr">204 </span> <a href='trace.mu.html#L140'>trace-lower</a> trace +<span id="L203" class="LineNr">203 </span> <a href='trace.mu.html#L120'>trace-text</a> trace, <span class="Constant">"read"</span>, <span class="Constant">"looking for a number"</span> +<span id="L204" class="LineNr">204 </span> <a href='trace.mu.html#L147'>trace-lower</a> trace <span id="L205" class="LineNr">205 </span> $next-number-token:<span class="PreProc">loop</span>: <span class="Delimiter">{</span> <span id="L206" class="LineNr">206 </span> <span class="PreProc">var</span> done?/<span class="Constant">eax</span>: boolean <span class="Special"><-</span> <a href='gap-buffer.mu.html#L748'>gap-buffer-scan-done?</a> in <span id="L207" class="LineNr">207 </span> compare done?, <span class="Constant">0</span>/false @@ -279,7 +279,7 @@ if ('onhashchange' in window) { <span id="L220" class="LineNr">220 </span> <span class="PreProc">var</span> <a href='tokenize.mu.html#L253'>symbol-grapheme?</a>/<span class="Constant">eax</span>: boolean <span class="Special"><-</span> <a href='tokenize.mu.html#L253'>symbol-grapheme?</a> g <span id="L221" class="LineNr">221 </span> compare <a href='tokenize.mu.html#L253'>symbol-grapheme?</a>, <span class="Constant">0</span>/false <span id="L222" class="LineNr">222 </span> <span class="PreProc">break-if-!=</span> -<span id="L223" class="LineNr">223 </span> <a href='trace.mu.html#L113'>trace-text</a> trace, <span class="Constant">"read"</span>, <span class="Constant">"stop"</span> +<span id="L223" class="LineNr">223 </span> <a href='trace.mu.html#L120'>trace-text</a> trace, <span class="Constant">"read"</span>, <span class="Constant">"stop"</span> <span id="L224" class="LineNr">224 </span> <span class="PreProc">break</span> $next-number-token:<span class="PreProc">loop</span> <span id="L225" class="LineNr">225 </span> <span class="Delimiter">}</span> <span id="L226" class="LineNr">226 </span> <span class="muComment"># if not digit grapheme, abort</span> @@ -287,19 +287,19 @@ if ('onhashchange' in window) { <span id="L228" class="LineNr">228 </span> <span class="PreProc">var</span> digit?/<span class="Constant">eax</span>: boolean <span class="Special"><-</span> <a href='../126write-int-decimal.subx.html#L299'>decimal-digit?</a> g <span id="L229" class="LineNr">229 </span> compare digit?, <span class="Constant">0</span>/false <span id="L230" class="LineNr">230 </span> <span class="PreProc">break-if-!=</span> -<span id="L231" class="LineNr">231 </span> <span class="Special"><a href='trace.mu.html#L122'>error</a></span> trace, <span class="Constant">"invalid number"</span> +<span id="L231" class="LineNr">231 </span> <span class="Special"><a href='trace.mu.html#L129'>error</a></span> trace, <span class="Constant">"invalid number"</span> <span id="L232" class="LineNr">232 </span> <span class="PreProc">return</span> <span id="L233" class="LineNr">233 </span> <span class="Delimiter">}</span> -<span id="L234" class="LineNr">234 </span> <a href='trace.mu.html#L113'>trace-text</a> trace, <span class="Constant">"read"</span>, <span class="Constant">"append"</span> +<span id="L234" class="LineNr">234 </span> <a href='trace.mu.html#L120'>trace-text</a> trace, <span class="Constant">"read"</span>, <span class="Constant">"append"</span> <span id="L235" class="LineNr">235 </span> <span class="PreProc">var</span> g/<span class="Constant">eax</span>: grapheme <span class="Special"><-</span> <a href='gap-buffer.mu.html#L808'>read-from-gap-buffer</a> in <span id="L236" class="LineNr">236 </span> <a href='../403unicode.mu.html#L176'>write-grapheme</a> out, g <span id="L237" class="LineNr">237 </span> <span class="PreProc">loop</span> <span id="L238" class="LineNr">238 </span> <span class="Delimiter">}</span> -<span id="L239" class="LineNr">239 </span> <a href='trace.mu.html#L148'>trace-higher</a> trace +<span id="L239" class="LineNr">239 </span> <a href='trace.mu.html#L155'>trace-higher</a> trace <span id="L240" class="LineNr">240 </span><span class="Delimiter">}</span> <span id="L241" class="LineNr">241 </span> <span id="L242" class="LineNr">242 </span><span class="PreProc">fn</span> <span class="muFunction"><a href='tokenize.mu.html#L242'>next-bracket-token</a></span> g: grapheme, out: (addr stream byte), trace: (addr trace) <span class="Delimiter">{</span> -<span id="L243" class="LineNr">243 </span> <a href='trace.mu.html#L113'>trace-text</a> trace, <span class="Constant">"read"</span>, <span class="Constant">"bracket"</span> +<span id="L243" class="LineNr">243 </span> <a href='trace.mu.html#L120'>trace-text</a> trace, <span class="Constant">"read"</span>, <span class="Constant">"bracket"</span> <span id="L244" class="LineNr">244 </span> <a href='../403unicode.mu.html#L176'>write-grapheme</a> out, g <span id="L245" class="LineNr">245 </span> <span class="PreProc">var</span> stream-storage: (stream byte <span class="Constant">0x40</span>) <span id="L246" class="LineNr">246 </span> <span class="PreProc">var</span> stream/<span class="Constant">esi</span>: (addr stream byte) <span class="Special"><-</span> address stream-storage |