about summary refs log tree commit diff stats
path: root/html/403unicode.mu.html
diff options
context:
space:
mode:
Diffstat (limited to 'html/403unicode.mu.html')
-rw-r--r--html/403unicode.mu.html173
1 files changed, 121 insertions, 52 deletions
diff --git a/html/403unicode.mu.html b/html/403unicode.mu.html
index d2ff2fc2..99b24b59 100644
--- a/html/403unicode.mu.html
+++ b/html/403unicode.mu.html
@@ -275,7 +275,7 @@ if ('onhashchange' in window) {
 <span id="L215" class="LineNr">215 </span>    <span class="PreProc">break-if-&lt;=</span>
 <span id="L216" class="LineNr">216 </span>    <span class="PreProc">var</span> tmp/<span class="Constant">eax</span>: byte <span class="SpecialChar">&lt;-</span> <a href='112read-byte.subx.html#L273'>read-byte</a> in
 <span id="L217" class="LineNr">217 </span>    <span class="PreProc">var</span> tmp2/<span class="Constant">eax</span>: int <span class="SpecialChar">&lt;-</span> copy tmp
-<span id="L218" class="LineNr">218 </span>    tmp2 <span class="SpecialChar">&lt;-</span> <a href='403unicode.mu.html#L257'>shift-left-bytes</a> tmp2, num-byte-shifts
+<span id="L218" class="LineNr">218 </span>    tmp2 <span class="SpecialChar">&lt;-</span> <a href='403unicode.mu.html#L326'>shift-left-bytes</a> tmp2, num-byte-shifts
 <span id="L219" class="LineNr">219 </span>    result <span class="SpecialChar">&lt;-</span> or tmp2
 <span id="L220" class="LineNr">220 </span>    <span class="Comment"># update loop state</span>
 <span id="L221" class="LineNr">221 </span>    num-byte-shifts <span class="SpecialChar">&lt;-</span> increment
@@ -313,57 +313,126 @@ if ('onhashchange' in window) {
 <span id="L253" class="LineNr">253 </span>  <a href='102test.subx.html#L23'>check-ints-equal</a> n, <span class="Constant">0x65</span>, <span class="Constant">&quot;F - test grapheme/6&quot;</span>
 <span id="L254" class="LineNr">254 </span><span class="Delimiter">}</span>
 <span id="L255" class="LineNr">255 </span>
-<span id="L256" class="LineNr">256 </span><span class="Comment"># needed because available primitives only shift by a literal/constant number of bits</span>
-<span id="L257" class="LineNr">257 </span><span class="PreProc">fn</span> <span class="muFunction"><a href='403unicode.mu.html#L257'>shift-left-bytes</a></span> n: int, k: int<span class="PreProc"> -&gt; </span>result/<span class="Constant">eax</span>: int <span class="Delimiter">{</span>
-<span id="L258" class="LineNr">258 </span>  <span class="PreProc">var</span> i/<span class="Constant">ecx</span>: int <span class="SpecialChar">&lt;-</span> copy <span class="Constant">0</span>
-<span id="L259" class="LineNr">259 </span>  result <span class="SpecialChar">&lt;-</span> copy n
-<span id="L260" class="LineNr">260 </span>  <span class="Delimiter">{</span>
-<span id="L261" class="LineNr">261 </span>    compare i, k
-<span id="L262" class="LineNr">262 </span>    <span class="PreProc">break-if-&gt;=</span>
-<span id="L263" class="LineNr">263 </span>    compare i, <span class="Constant">4</span>  <span class="Comment"># only 4 bytes in 32 bits</span>
-<span id="L264" class="LineNr">264 </span>    <span class="PreProc">break-if-&gt;=</span>
-<span id="L265" class="LineNr">265 </span>    result <span class="SpecialChar">&lt;-</span> shift-left <span class="Constant">8</span>
-<span id="L266" class="LineNr">266 </span>    i <span class="SpecialChar">&lt;-</span> increment
-<span id="L267" class="LineNr">267 </span>    <span class="PreProc">loop</span>
-<span id="L268" class="LineNr">268 </span>  <span class="Delimiter">}</span>
-<span id="L269" class="LineNr">269 </span><span class="Delimiter">}</span>
-<span id="L270" class="LineNr">270 </span>
-<span id="L271" class="LineNr">271 </span><span class="PreProc">fn</span> <span class="muTest"><a href='403unicode.mu.html#L271'>test-shift-left-bytes-0</a></span> <span class="Delimiter">{</span>
-<span id="L272" class="LineNr">272 </span>  <span class="PreProc">var</span> result/<span class="Constant">eax</span>: int <span class="SpecialChar">&lt;-</span> <a href='403unicode.mu.html#L257'>shift-left-bytes</a> <span class="Constant">1</span>, <span class="Constant">0</span>
-<span id="L273" class="LineNr">273 </span>  <a href='102test.subx.html#L23'>check-ints-equal</a> result, <span class="Constant">1</span>, <span class="Constant">&quot;F - <a href='403unicode.mu.html#L257'>shift-left-bytes</a> 0&quot;</span>
-<span id="L274" class="LineNr">274 </span><span class="Delimiter">}</span>
-<span id="L275" class="LineNr">275 </span>
-<span id="L276" class="LineNr">276 </span><span class="PreProc">fn</span> <span class="muTest"><a href='403unicode.mu.html#L276'>test-shift-left-bytes-1</a></span> <span class="Delimiter">{</span>
-<span id="L277" class="LineNr">277 </span>  <span class="PreProc">var</span> result/<span class="Constant">eax</span>: int <span class="SpecialChar">&lt;-</span> <a href='403unicode.mu.html#L257'>shift-left-bytes</a> <span class="Constant">1</span>, <span class="Constant">1</span>
-<span id="L278" class="LineNr">278 </span>  <a href='102test.subx.html#L23'>check-ints-equal</a> result, <span class="Constant">0x100</span>, <span class="Constant">&quot;F - <a href='403unicode.mu.html#L257'>shift-left-bytes</a> 1&quot;</span>
-<span id="L279" class="LineNr">279 </span><span class="Delimiter">}</span>
-<span id="L280" class="LineNr">280 </span>
-<span id="L281" class="LineNr">281 </span><span class="PreProc">fn</span> <span class="muTest"><a href='403unicode.mu.html#L281'>test-shift-left-bytes-2</a></span> <span class="Delimiter">{</span>
-<span id="L282" class="LineNr">282 </span>  <span class="PreProc">var</span> result/<span class="Constant">eax</span>: int <span class="SpecialChar">&lt;-</span> <a href='403unicode.mu.html#L257'>shift-left-bytes</a> <span class="Constant">1</span>, <span class="Constant">2</span>
-<span id="L283" class="LineNr">283 </span>  <a href='102test.subx.html#L23'>check-ints-equal</a> result, <span class="Constant">0x10000</span>, <span class="Constant">&quot;F - <a href='403unicode.mu.html#L257'>shift-left-bytes</a> 2&quot;</span>
-<span id="L284" class="LineNr">284 </span><span class="Delimiter">}</span>
-<span id="L285" class="LineNr">285 </span>
-<span id="L286" class="LineNr">286 </span><span class="PreProc">fn</span> <span class="muTest"><a href='403unicode.mu.html#L286'>test-shift-left-bytes-3</a></span> <span class="Delimiter">{</span>
-<span id="L287" class="LineNr">287 </span>  <span class="PreProc">var</span> result/<span class="Constant">eax</span>: int <span class="SpecialChar">&lt;-</span> <a href='403unicode.mu.html#L257'>shift-left-bytes</a> <span class="Constant">1</span>, <span class="Constant">3</span>
-<span id="L288" class="LineNr">288 </span>  <a href='102test.subx.html#L23'>check-ints-equal</a> result, <span class="Constant">0x1000000</span>, <span class="Constant">&quot;F - <a href='403unicode.mu.html#L257'>shift-left-bytes</a> 3&quot;</span>
-<span id="L289" class="LineNr">289 </span><span class="Delimiter">}</span>
-<span id="L290" class="LineNr">290 </span>
-<span id="L291" class="LineNr">291 </span><span class="PreProc">fn</span> <span class="muTest"><a href='403unicode.mu.html#L291'>test-shift-left-bytes-4</a></span> <span class="Delimiter">{</span>
-<span id="L292" class="LineNr">292 </span>  <span class="PreProc">var</span> result/<span class="Constant">eax</span>: int <span class="SpecialChar">&lt;-</span> <a href='403unicode.mu.html#L257'>shift-left-bytes</a> <span class="Constant">1</span>, <span class="Constant">4</span>
-<span id="L293" class="LineNr">293 </span>  <a href='102test.subx.html#L23'>check-ints-equal</a> result, <span class="Constant">0</span>, <span class="Constant">&quot;F - <a href='403unicode.mu.html#L257'>shift-left-bytes</a> 4&quot;</span>
-<span id="L294" class="LineNr">294 </span><span class="Delimiter">}</span>
-<span id="L295" class="LineNr">295 </span>
-<span id="L296" class="LineNr">296 </span><span class="PreProc">fn</span> <span class="muTest"><a href='403unicode.mu.html#L296'>test-shift-left-bytes-5</a></span> <span class="Delimiter">{</span>
-<span id="L297" class="LineNr">297 </span>  <span class="PreProc">var</span> result/<span class="Constant">eax</span>: int <span class="SpecialChar">&lt;-</span> <a href='403unicode.mu.html#L257'>shift-left-bytes</a> <span class="Constant">1</span>, <span class="Constant">5</span>
-<span id="L298" class="LineNr">298 </span>  <a href='102test.subx.html#L23'>check-ints-equal</a> result, <span class="Constant">0</span>, <span class="Constant">&quot;F - <a href='403unicode.mu.html#L257'>shift-left-bytes</a> &gt;4&quot;</span>
-<span id="L299" class="LineNr">299 </span><span class="Delimiter">}</span>
-<span id="L300" class="LineNr">300 </span>
-<span id="L301" class="LineNr">301 </span><span class="Comment"># To run all tests, uncomment this and run:</span>
-<span id="L302" class="LineNr">302 </span><span class="Comment">#   $ ./translate_mu  &amp;&amp;  ./a.elf</span>
-<span id="L303" class="LineNr">303 </span><span class="CommentedCode">#? fn main -&gt; r/ebx: int {</span>
-<span id="L304" class="LineNr">304 </span><span class="CommentedCode">#?   run-tests</span>
-<span id="L305" class="LineNr">305 </span><span class="CommentedCode">#?   r &lt;- copy 0</span>
-<span id="L306" class="LineNr">306 </span><span class="CommentedCode">#? }</span>
+<span id="L256" class="LineNr">256 </span><span class="PreProc">fn</span> <span class="muFunction"><a href='403unicode.mu.html#L256'>read-grapheme-buffered</a></span> in: (addr buffered-file)<span class="PreProc"> -&gt; </span>out/<span class="Constant">eax</span>: grapheme <span class="Delimiter">{</span>
+<span id="L257" class="LineNr">257 </span>$read-grapheme-buffered:body: <span class="Delimiter">{</span>
+<span id="L258" class="LineNr">258 </span>  <span class="PreProc">var</span> c/<span class="Constant">eax</span>: byte <span class="SpecialChar">&lt;-</span> <a href='112read-byte.subx.html#L38'>read-byte-buffered</a> in
+<span id="L259" class="LineNr">259 </span>  <span class="PreProc">var</span> num-trailers/<span class="Constant">ecx</span>: int <span class="SpecialChar">&lt;-</span> copy <span class="Constant">0</span>
+<span id="L260" class="LineNr">260 </span>  $read-grapheme-buffered:compute-length: <span class="Delimiter">{</span>
+<span id="L261" class="LineNr">261 </span>    <span class="Comment"># single byte: just return it</span>
+<span id="L262" class="LineNr">262 </span>    compare c, <span class="Constant">0xc0</span>
+<span id="L263" class="LineNr">263 </span>    <span class="Delimiter">{</span>
+<span id="L264" class="LineNr">264 </span>      <span class="PreProc">break-if-&gt;=</span>
+<span id="L265" class="LineNr">265 </span>      out <span class="SpecialChar">&lt;-</span> copy c
+<span id="L266" class="LineNr">266 </span>      num-trailers <span class="SpecialChar">&lt;-</span> copy <span class="Constant">0</span>
+<span id="L267" class="LineNr">267 </span>      <span class="PreProc">break</span> $read-grapheme-buffered:body
+<span id="L268" class="LineNr">268 </span>    <span class="Delimiter">}</span>
+<span id="L269" class="LineNr">269 </span>    compare c, <span class="Constant">0xfe</span>
+<span id="L270" class="LineNr">270 </span>    <span class="Delimiter">{</span>
+<span id="L271" class="LineNr">271 </span>      <span class="PreProc">break-if-&lt;</span>
+<span id="L272" class="LineNr">272 </span>      out <span class="SpecialChar">&lt;-</span> copy c
+<span id="L273" class="LineNr">273 </span>      <span class="PreProc">break</span> $read-grapheme-buffered:body
+<span id="L274" class="LineNr">274 </span>    <span class="Delimiter">}</span>
+<span id="L275" class="LineNr">275 </span>    <span class="Comment"># 2 bytes</span>
+<span id="L276" class="LineNr">276 </span>    compare c, <span class="Constant">0xe0</span>
+<span id="L277" class="LineNr">277 </span>    <span class="Delimiter">{</span>
+<span id="L278" class="LineNr">278 </span>      <span class="PreProc">break-if-&gt;=</span>
+<span id="L279" class="LineNr">279 </span>      num-trailers <span class="SpecialChar">&lt;-</span> copy <span class="Constant">1</span>
+<span id="L280" class="LineNr">280 </span>      <span class="PreProc">break</span> $read-grapheme-buffered:compute-length
+<span id="L281" class="LineNr">281 </span>    <span class="Delimiter">}</span>
+<span id="L282" class="LineNr">282 </span>    <span class="Comment"># 3 bytes</span>
+<span id="L283" class="LineNr">283 </span>    compare c, <span class="Constant">0xf0</span>
+<span id="L284" class="LineNr">284 </span>    <span class="Delimiter">{</span>
+<span id="L285" class="LineNr">285 </span>      <span class="PreProc">break-if-&gt;=</span>
+<span id="L286" class="LineNr">286 </span>      num-trailers <span class="SpecialChar">&lt;-</span> copy <span class="Constant">2</span>
+<span id="L287" class="LineNr">287 </span>      <span class="PreProc">break</span> $read-grapheme-buffered:compute-length
+<span id="L288" class="LineNr">288 </span>    <span class="Delimiter">}</span>
+<span id="L289" class="LineNr">289 </span>    <span class="Comment"># 4 bytes</span>
+<span id="L290" class="LineNr">290 </span>    compare c, <span class="Constant">0xf8</span>
+<span id="L291" class="LineNr">291 </span>    <span class="Delimiter">{</span>
+<span id="L292" class="LineNr">292 </span>      <span class="PreProc">break-if-&gt;=</span>
+<span id="L293" class="LineNr">293 </span>      num-trailers <span class="SpecialChar">&lt;-</span> copy <span class="Constant">3</span>
+<span id="L294" class="LineNr">294 </span>      <span class="PreProc">break</span> $read-grapheme-buffered:compute-length
+<span id="L295" class="LineNr">295 </span>    <span class="Delimiter">}</span>
+<span id="L296" class="LineNr">296 </span>$read-grapheme-buffered:abort: <span class="Delimiter">{</span>
+<span id="L297" class="LineNr">297 </span>      <span class="Comment"># TODO: print to stderr</span>
+<span id="L298" class="LineNr">298 </span>      <a href='304screen.subx.html#L122'>print-string-to-real-screen</a> <span class="Constant">&quot;utf-8 encodings larger than 4 bytes are not supported. First byte seen: &quot;</span>
+<span id="L299" class="LineNr">299 </span>      <span class="PreProc">var</span> n/<span class="Constant">eax</span>: int <span class="SpecialChar">&lt;-</span> copy c
+<span id="L300" class="LineNr">300 </span>      <a href='304screen.subx.html#L213'>print-int32-hex-to-real-screen</a> n
+<span id="L301" class="LineNr">301 </span>      <a href='304screen.subx.html#L122'>print-string-to-real-screen</a> <span class="Constant">&quot;\n&quot;</span>
+<span id="L302" class="LineNr">302 </span>      <span class="PreProc">var</span> exit-status/<span class="Constant">ebx</span>: int <span class="SpecialChar">&lt;-</span> copy <span class="Constant">1</span>
+<span id="L303" class="LineNr">303 </span>      syscall_exit
+<span id="L304" class="LineNr">304 </span>    <span class="Delimiter">}</span>
+<span id="L305" class="LineNr">305 </span>  <span class="Delimiter">}</span>
+<span id="L306" class="LineNr">306 </span>  <span class="Comment"># prepend trailer bytes</span>
+<span id="L307" class="LineNr">307 </span>  <span class="PreProc">var</span> result/<span class="Constant">edi</span>: int <span class="SpecialChar">&lt;-</span> copy c
+<span id="L308" class="LineNr">308 </span>  <span class="PreProc">var</span> num-byte-shifts/<span class="Constant">edx</span>: int <span class="SpecialChar">&lt;-</span> copy <span class="Constant">1</span>
+<span id="L309" class="LineNr">309 </span>  <span class="Delimiter">{</span>
+<span id="L310" class="LineNr">310 </span>    compare num-trailers, <span class="Constant">0</span>
+<span id="L311" class="LineNr">311 </span>    <span class="PreProc">break-if-&lt;=</span>
+<span id="L312" class="LineNr">312 </span>    <span class="PreProc">var</span> tmp/<span class="Constant">eax</span>: byte <span class="SpecialChar">&lt;-</span> <a href='112read-byte.subx.html#L38'>read-byte-buffered</a> in
+<span id="L313" class="LineNr">313 </span>    <span class="PreProc">var</span> tmp2/<span class="Constant">eax</span>: int <span class="SpecialChar">&lt;-</span> copy tmp
+<span id="L314" class="LineNr">314 </span>    tmp2 <span class="SpecialChar">&lt;-</span> <a href='403unicode.mu.html#L326'>shift-left-bytes</a> tmp2, num-byte-shifts
+<span id="L315" class="LineNr">315 </span>    result <span class="SpecialChar">&lt;-</span> or tmp2
+<span id="L316" class="LineNr">316 </span>    <span class="Comment"># update loop state</span>
+<span id="L317" class="LineNr">317 </span>    num-byte-shifts <span class="SpecialChar">&lt;-</span> increment
+<span id="L318" class="LineNr">318 </span>    num-trailers <span class="SpecialChar">&lt;-</span> decrement
+<span id="L319" class="LineNr">319 </span>    <span class="PreProc">loop</span>
+<span id="L320" class="LineNr">320 </span>  <span class="Delimiter">}</span>
+<span id="L321" class="LineNr">321 </span>  out <span class="SpecialChar">&lt;-</span> copy result
+<span id="L322" class="LineNr">322 </span><span class="Delimiter">}</span>
+<span id="L323" class="LineNr">323 </span><span class="Delimiter">}</span>
+<span id="L324" class="LineNr">324 </span>
+<span id="L325" class="LineNr">325 </span><span class="Comment"># needed because available primitives only shift by a literal/constant number of bits</span>
+<span id="L326" class="LineNr">326 </span><span class="PreProc">fn</span> <span class="muFunction"><a href='403unicode.mu.html#L326'>shift-left-bytes</a></span> n: int, k: int<span class="PreProc"> -&gt; </span>result/<span class="Constant">eax</span>: int <span class="Delimiter">{</span>
+<span id="L327" class="LineNr">327 </span>  <span class="PreProc">var</span> i/<span class="Constant">ecx</span>: int <span class="SpecialChar">&lt;-</span> copy <span class="Constant">0</span>
+<span id="L328" class="LineNr">328 </span>  result <span class="SpecialChar">&lt;-</span> copy n
+<span id="L329" class="LineNr">329 </span>  <span class="Delimiter">{</span>
+<span id="L330" class="LineNr">330 </span>    compare i, k
+<span id="L331" class="LineNr">331 </span>    <span class="PreProc">break-if-&gt;=</span>
+<span id="L332" class="LineNr">332 </span>    compare i, <span class="Constant">4</span>  <span class="Comment"># only 4 bytes in 32 bits</span>
+<span id="L333" class="LineNr">333 </span>    <span class="PreProc">break-if-&gt;=</span>
+<span id="L334" class="LineNr">334 </span>    result <span class="SpecialChar">&lt;-</span> shift-left <span class="Constant">8</span>
+<span id="L335" class="LineNr">335 </span>    i <span class="SpecialChar">&lt;-</span> increment
+<span id="L336" class="LineNr">336 </span>    <span class="PreProc">loop</span>
+<span id="L337" class="LineNr">337 </span>  <span class="Delimiter">}</span>
+<span id="L338" class="LineNr">338 </span><span class="Delimiter">}</span>
+<span id="L339" class="LineNr">339 </span>
+<span id="L340" class="LineNr">340 </span><span class="PreProc">fn</span> <span class="muTest"><a href='403unicode.mu.html#L340'>test-shift-left-bytes-0</a></span> <span class="Delimiter">{</span>
+<span id="L341" class="LineNr">341 </span>  <span class="PreProc">var</span> result/<span class="Constant">eax</span>: int <span class="SpecialChar">&lt;-</span> <a href='403unicode.mu.html#L326'>shift-left-bytes</a> <span class="Constant">1</span>, <span class="Constant">0</span>
+<span id="L342" class="LineNr">342 </span>  <a href='102test.subx.html#L23'>check-ints-equal</a> result, <span class="Constant">1</span>, <span class="Constant">&quot;F - <a href='403unicode.mu.html#L326'>shift-left-bytes</a> 0&quot;</span>
+<span id="L343" class="LineNr">343 </span><span class="Delimiter">}</span>
+<span id="L344" class="LineNr">344 </span>
+<span id="L345" class="LineNr">345 </span><span class="PreProc">fn</span> <span class="muTest"><a href='403unicode.mu.html#L345'>test-shift-left-bytes-1</a></span> <span class="Delimiter">{</span>
+<span id="L346" class="LineNr">346 </span>  <span class="PreProc">var</span> result/<span class="Constant">eax</span>: int <span class="SpecialChar">&lt;-</span> <a href='403unicode.mu.html#L326'>shift-left-bytes</a> <span class="Constant">1</span>, <span class="Constant">1</span>
+<span id="L347" class="LineNr">347 </span>  <a href='102test.subx.html#L23'>check-ints-equal</a> result, <span class="Constant">0x100</span>, <span class="Constant">&quot;F - <a href='403unicode.mu.html#L326'>shift-left-bytes</a> 1&quot;</span>
+<span id="L348" class="LineNr">348 </span><span class="Delimiter">}</span>
+<span id="L349" class="LineNr">349 </span>
+<span id="L350" class="LineNr">350 </span><span class="PreProc">fn</span> <span class="muTest"><a href='403unicode.mu.html#L350'>test-shift-left-bytes-2</a></span> <span class="Delimiter">{</span>
+<span id="L351" class="LineNr">351 </span>  <span class="PreProc">var</span> result/<span class="Constant">eax</span>: int <span class="SpecialChar">&lt;-</span> <a href='403unicode.mu.html#L326'>shift-left-bytes</a> <span class="Constant">1</span>, <span class="Constant">2</span>
+<span id="L352" class="LineNr">352 </span>  <a href='102test.subx.html#L23'>check-ints-equal</a> result, <span class="Constant">0x10000</span>, <span class="Constant">&quot;F - <a href='403unicode.mu.html#L326'>shift-left-bytes</a> 2&quot;</span>
+<span id="L353" class="LineNr">353 </span><span class="Delimiter">}</span>
+<span id="L354" class="LineNr">354 </span>
+<span id="L355" class="LineNr">355 </span><span class="PreProc">fn</span> <span class="muTest"><a href='403unicode.mu.html#L355'>test-shift-left-bytes-3</a></span> <span class="Delimiter">{</span>
+<span id="L356" class="LineNr">356 </span>  <span class="PreProc">var</span> result/<span class="Constant">eax</span>: int <span class="SpecialChar">&lt;-</span> <a href='403unicode.mu.html#L326'>shift-left-bytes</a> <span class="Constant">1</span>, <span class="Constant">3</span>
+<span id="L357" class="LineNr">357 </span>  <a href='102test.subx.html#L23'>check-ints-equal</a> result, <span class="Constant">0x1000000</span>, <span class="Constant">&quot;F - <a href='403unicode.mu.html#L326'>shift-left-bytes</a> 3&quot;</span>
+<span id="L358" class="LineNr">358 </span><span class="Delimiter">}</span>
+<span id="L359" class="LineNr">359 </span>
+<span id="L360" class="LineNr">360 </span><span class="PreProc">fn</span> <span class="muTest"><a href='403unicode.mu.html#L360'>test-shift-left-bytes-4</a></span> <span class="Delimiter">{</span>
+<span id="L361" class="LineNr">361 </span>  <span class="PreProc">var</span> result/<span class="Constant">eax</span>: int <span class="SpecialChar">&lt;-</span> <a href='403unicode.mu.html#L326'>shift-left-bytes</a> <span class="Constant">1</span>, <span class="Constant">4</span>
+<span id="L362" class="LineNr">362 </span>  <a href='102test.subx.html#L23'>check-ints-equal</a> result, <span class="Constant">0</span>, <span class="Constant">&quot;F - <a href='403unicode.mu.html#L326'>shift-left-bytes</a> 4&quot;</span>
+<span id="L363" class="LineNr">363 </span><span class="Delimiter">}</span>
+<span id="L364" class="LineNr">364 </span>
+<span id="L365" class="LineNr">365 </span><span class="PreProc">fn</span> <span class="muTest"><a href='403unicode.mu.html#L365'>test-shift-left-bytes-5</a></span> <span class="Delimiter">{</span>
+<span id="L366" class="LineNr">366 </span>  <span class="PreProc">var</span> result/<span class="Constant">eax</span>: int <span class="SpecialChar">&lt;-</span> <a href='403unicode.mu.html#L326'>shift-left-bytes</a> <span class="Constant">1</span>, <span class="Constant">5</span>
+<span id="L367" class="LineNr">367 </span>  <a href='102test.subx.html#L23'>check-ints-equal</a> result, <span class="Constant">0</span>, <span class="Constant">&quot;F - <a href='403unicode.mu.html#L326'>shift-left-bytes</a> &gt;4&quot;</span>
+<span id="L368" class="LineNr">368 </span><span class="Delimiter">}</span>
+<span id="L369" class="LineNr">369 </span>
+<span id="L370" class="LineNr">370 </span><span class="Comment"># To run all tests, uncomment this and run:</span>
+<span id="L371" class="LineNr">371 </span><span class="Comment">#   $ ./translate_mu  &amp;&amp;  ./a.elf</span>
+<span id="L372" class="LineNr">372 </span><span class="CommentedCode">#? fn main -&gt; r/ebx: int {</span>
+<span id="L373" class="LineNr">373 </span><span class="CommentedCode">#?   run-tests</span>
+<span id="L374" class="LineNr">374 </span><span class="CommentedCode">#?   r &lt;- copy 0</span>
+<span id="L375" class="LineNr">375 </span><span class="CommentedCode">#? }</span>
 </pre>
 </body>
 </html>