diff options
author | Kartik K. Agaram <vc@akkartik.com> | 2017-03-02 04:41:24 -0800 |
---|---|---|
committer | Kartik K. Agaram <vc@akkartik.com> | 2017-03-02 04:41:24 -0800 |
commit | a802f0cedc7b5580d746f46ae62fcf8074ae3c49 (patch) | |
tree | ab8f531d51374491f2998f63239dbb767b21e493 /html/038new_text.cc.html | |
parent | a1e4fa7194da184b74083362de537ece23a2f2f1 (diff) | |
download | mu-a802f0cedc7b5580d746f46ae62fcf8074ae3c49.tar.gz |
3749
Diffstat (limited to 'html/038new_text.cc.html')
-rw-r--r-- | html/038new_text.cc.html | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/html/038new_text.cc.html b/html/038new_text.cc.html index e883bc95..6c16b620 100644 --- a/html/038new_text.cc.html +++ b/html/038new_text.cc.html @@ -93,7 +93,7 @@ if ('onhashchange' in window) { <span id="L30" class="LineNr"> 30 </span> <span class="Normal">if</span> <span class="Delimiter">(</span><a href='014literal_string.cc.html#L126'>is_literal_text</a><span class="Delimiter">(</span>current_instruction<span class="Delimiter">().</span>ingredients<span class="Delimiter">.</span>at<span class="Delimiter">(</span><span class="Constant">0</span><span class="Delimiter">)))</span> <span class="Delimiter">{</span> <span id="L31" class="LineNr"> 31 </span> products<span class="Delimiter">.</span>resize<span class="Delimiter">(</span><span class="Constant">1</span><span class="Delimiter">);</span> <span id="L32" class="LineNr"> 32 </span> products<span class="Delimiter">.</span>at<span class="Delimiter">(</span><span class="Constant">0</span><span class="Delimiter">).</span>push_back<span class="Delimiter">(</span><a href='038new_text.cc.html#L38'>new_mu_text</a><span class="Delimiter">(</span>current_instruction<span class="Delimiter">().</span>ingredients<span class="Delimiter">.</span>at<span class="Delimiter">(</span><span class="Constant">0</span><span class="Delimiter">).</span>name<span class="Delimiter">));</span> -<span id="L33" class="LineNr"> 33 </span> <a href='003trace.cc.html#L171'>trace</a><span class="Delimiter">(</span><span class="Constant">9999</span><span class="Delimiter">,</span> <span class="Constant">"mem"</span><span class="Delimiter">)</span> << <span class="Constant">"new string alloc: "</span> << products<span class="Delimiter">.</span>at<span class="Delimiter">(</span><span class="Constant">0</span><span class="Delimiter">).</span>at<span class="Delimiter">(</span><span class="Constant">0</span><span class="Delimiter">)</span> << <a href='003trace.cc.html#L195'>end</a><span class="Delimiter">();</span> +<span id="L33" class="LineNr"> 33 </span> <a href='003trace.cc.html#L169'>trace</a><span class="Delimiter">(</span><span class="Constant">9999</span><span class="Delimiter">,</span> <span class="Constant">"mem"</span><span class="Delimiter">)</span> << <span class="Constant">"new string alloc: "</span> << products<span class="Delimiter">.</span>at<span class="Delimiter">(</span><span class="Constant">0</span><span class="Delimiter">).</span>at<span class="Delimiter">(</span><span class="Constant">0</span><span class="Delimiter">)</span> << <a href='003trace.cc.html#L193'>end</a><span class="Delimiter">();</span> <span id="L34" class="LineNr"> 34 </span> <span class="Identifier">break</span><span class="Delimiter">;</span> <span id="L35" class="LineNr"> 35 </span> <span class="Delimiter">}</span> <span id="L36" class="LineNr"> 36 </span> @@ -104,10 +104,10 @@ if ('onhashchange' in window) { <span id="L41" class="LineNr"> 41 </span><span class="CommentedCode">//? Total_alloc += string_length+1;</span> <span id="L42" class="LineNr"> 42 </span><span class="CommentedCode">//? ++Num_alloc;</span> <span id="L43" class="LineNr"> 43 </span> <span class="Normal">int</span> result = allocate<span class="Delimiter">(</span>string_length+<span class="Comment">/*</span><span class="Comment">array length</span><span class="Comment">*/</span><span class="Constant">1</span><span class="Delimiter">);</span> -<span id="L44" class="LineNr"> 44 </span> <a href='003trace.cc.html#L171'>trace</a><span class="Delimiter">(</span><span class="Constant">9999</span><span class="Delimiter">,</span> <span class="Constant">"mem"</span><span class="Delimiter">)</span> << <span class="Constant">"storing string refcount 0 in location "</span> << result << <a href='003trace.cc.html#L195'>end</a><span class="Delimiter">();</span> +<span id="L44" class="LineNr"> 44 </span> <a href='003trace.cc.html#L169'>trace</a><span class="Delimiter">(</span><span class="Constant">9999</span><span class="Delimiter">,</span> <span class="Constant">"mem"</span><span class="Delimiter">)</span> << <span class="Constant">"storing string refcount 0 in location "</span> << result << <a href='003trace.cc.html#L193'>end</a><span class="Delimiter">();</span> <span id="L45" class="LineNr"> 45 </span> <a href='001help.cc.html#L218'>put</a><span class="Delimiter">(</span>Memory<span class="Delimiter">,</span> result<span class="Delimiter">,</span> <span class="Constant">0</span><span class="Delimiter">);</span> <span id="L46" class="LineNr"> 46 </span> <span class="Normal">int</span> curr_address = result+<span class="Comment">/*</span><span class="Comment">skip refcount</span><span class="Comment">*/</span><span class="Constant">1</span><span class="Delimiter">;</span> -<span id="L47" class="LineNr"> 47 </span> <a href='003trace.cc.html#L171'>trace</a><span class="Delimiter">(</span><span class="Constant">9999</span><span class="Delimiter">,</span> <span class="Constant">"mem"</span><span class="Delimiter">)</span> << <span class="Constant">"storing string length "</span> << string_length << <span class="Constant">" in location "</span> << curr_address << <a href='003trace.cc.html#L195'>end</a><span class="Delimiter">();</span> +<span id="L47" class="LineNr"> 47 </span> <a href='003trace.cc.html#L169'>trace</a><span class="Delimiter">(</span><span class="Constant">9999</span><span class="Delimiter">,</span> <span class="Constant">"mem"</span><span class="Delimiter">)</span> << <span class="Constant">"storing string length "</span> << string_length << <span class="Constant">" in location "</span> << curr_address << <a href='003trace.cc.html#L193'>end</a><span class="Delimiter">();</span> <span id="L48" class="LineNr"> 48 </span> <a href='001help.cc.html#L218'>put</a><span class="Delimiter">(</span>Memory<span class="Delimiter">,</span> curr_address<span class="Delimiter">,</span> string_length<span class="Delimiter">);</span> <span id="L49" class="LineNr"> 49 </span> ++curr_address<span class="Delimiter">;</span> <span class="Comment">// skip length</span> <span id="L50" class="LineNr"> 50 </span> <span class="Normal">int</span> curr = <span class="Constant">0</span><span class="Delimiter">;</span> @@ -116,7 +116,7 @@ if ('onhashchange' in window) { <span id="L53" class="LineNr"> 53 </span> <span class="Normal">uint32_t</span> curr_character<span class="Delimiter">;</span> <span id="L54" class="LineNr"> 54 </span> assert<span class="Delimiter">(</span>curr < <a href='001help.cc.html#L138'>SIZE</a><span class="Delimiter">(</span>contents<span class="Delimiter">));</span> <span id="L55" class="LineNr"> 55 </span> tb_utf8_char_to_unicode<span class="Delimiter">(</span>&curr_character<span class="Delimiter">,</span> &raw_contents[curr]<span class="Delimiter">);</span> -<span id="L56" class="LineNr"> 56 </span> <a href='003trace.cc.html#L171'>trace</a><span class="Delimiter">(</span><span class="Constant">9999</span><span class="Delimiter">,</span> <span class="Constant">"mem"</span><span class="Delimiter">)</span> << <span class="Constant">"storing string character "</span> << curr_character << <span class="Constant">" in location "</span> << curr_address << <a href='003trace.cc.html#L195'>end</a><span class="Delimiter">();</span> +<span id="L56" class="LineNr"> 56 </span> <a href='003trace.cc.html#L169'>trace</a><span class="Delimiter">(</span><span class="Constant">9999</span><span class="Delimiter">,</span> <span class="Constant">"mem"</span><span class="Delimiter">)</span> << <span class="Constant">"storing string character "</span> << curr_character << <span class="Constant">" in location "</span> << curr_address << <a href='003trace.cc.html#L193'>end</a><span class="Delimiter">();</span> <span id="L57" class="LineNr"> 57 </span> <a href='001help.cc.html#L218'>put</a><span class="Delimiter">(</span>Memory<span class="Delimiter">,</span> curr_address<span class="Delimiter">,</span> curr_character<span class="Delimiter">);</span> <span id="L58" class="LineNr"> 58 </span> curr += tb_utf8_char_length<span class="Delimiter">(</span>raw_contents[curr]<span class="Delimiter">);</span> <span id="L59" class="LineNr"> 59 </span> ++curr_address<span class="Delimiter">;</span> @@ -233,15 +233,15 @@ if ('onhashchange' in window) { <span id="L170" class="LineNr">170 </span><span class="Delimiter">:(before "End Primitive Recipe Checks")</span> <span id="L171" class="LineNr">171 </span><span class="Normal">case</span> ASSERT: <span class="Delimiter">{</span> <span id="L172" class="LineNr">172 </span> <span class="Normal">if</span> <span class="Delimiter">(</span><a href='001help.cc.html#L138'>SIZE</a><span class="Delimiter">(</span>inst<span class="Delimiter">.</span>ingredients<span class="Delimiter">)</span> != <span class="Constant">2</span><span class="Delimiter">)</span> <span class="Delimiter">{</span> -<span id="L173" class="LineNr">173 </span> <a href='003trace.cc.html#L178'>raise</a> << <a href='013update_operation.cc.html#L25'>maybe</a><span class="Delimiter">(</span>get<span class="Delimiter">(</span>Recipe<span class="Delimiter">,</span> r<span class="Delimiter">).</span>name<span class="Delimiter">)</span> << <span class="Constant">"'assert' takes exactly two ingredients rather than '"</span> << inst<span class="Delimiter">.</span>original_string << <span class="Constant">"'</span><span class="cSpecial">\n</span><span class="Constant">"</span> << <a href='003trace.cc.html#L195'>end</a><span class="Delimiter">();</span> +<span id="L173" class="LineNr">173 </span> <a href='003trace.cc.html#L176'>raise</a> << <a href='013update_operation.cc.html#L25'>maybe</a><span class="Delimiter">(</span>get<span class="Delimiter">(</span>Recipe<span class="Delimiter">,</span> r<span class="Delimiter">).</span>name<span class="Delimiter">)</span> << <span class="Constant">"'assert' takes exactly two ingredients rather than '"</span> << inst<span class="Delimiter">.</span>original_string << <span class="Constant">"'</span><span class="cSpecial">\n</span><span class="Constant">"</span> << <a href='003trace.cc.html#L193'>end</a><span class="Delimiter">();</span> <span id="L174" class="LineNr">174 </span> <span class="Identifier">break</span><span class="Delimiter">;</span> <span id="L175" class="LineNr">175 </span> <span class="Delimiter">}</span> <span id="L176" class="LineNr">176 </span> <span class="Normal">if</span> <span class="Delimiter">(</span>!is_mu_scalar<span class="Delimiter">(</span>inst<span class="Delimiter">.</span>ingredients<span class="Delimiter">.</span>at<span class="Delimiter">(</span><span class="Constant">0</span><span class="Delimiter">)))</span> <span class="Delimiter">{</span> -<span id="L177" class="LineNr">177 </span> <a href='003trace.cc.html#L178'>raise</a> << <a href='013update_operation.cc.html#L25'>maybe</a><span class="Delimiter">(</span>get<span class="Delimiter">(</span>Recipe<span class="Delimiter">,</span> r<span class="Delimiter">).</span>name<span class="Delimiter">)</span> << <span class="Constant">"'assert' requires a boolean for its first ingredient, but got '"</span> << inst<span class="Delimiter">.</span>ingredients<span class="Delimiter">.</span>at<span class="Delimiter">(</span><span class="Constant">0</span><span class="Delimiter">).</span>original_string << <span class="Constant">"'</span><span class="cSpecial">\n</span><span class="Constant">"</span> << <a href='003trace.cc.html#L195'>end</a><span class="Delimiter">();</span> +<span id="L177" class="LineNr">177 </span> <a href='003trace.cc.html#L176'>raise</a> << <a href='013update_operation.cc.html#L25'>maybe</a><span class="Delimiter">(</span>get<span class="Delimiter">(</span>Recipe<span class="Delimiter">,</span> r<span class="Delimiter">).</span>name<span class="Delimiter">)</span> << <span class="Constant">"'assert' requires a boolean for its first ingredient, but got '"</span> << inst<span class="Delimiter">.</span>ingredients<span class="Delimiter">.</span>at<span class="Delimiter">(</span><span class="Constant">0</span><span class="Delimiter">).</span>original_string << <span class="Constant">"'</span><span class="cSpecial">\n</span><span class="Constant">"</span> << <a href='003trace.cc.html#L193'>end</a><span class="Delimiter">();</span> <span id="L178" class="LineNr">178 </span> <span class="Identifier">break</span><span class="Delimiter">;</span> <span id="L179" class="LineNr">179 </span> <span class="Delimiter">}</span> <span id="L180" class="LineNr">180 </span> <span class="Normal">if</span> <span class="Delimiter">(</span>!is_literal_text<span class="Delimiter">(</span>inst<span class="Delimiter">.</span>ingredients<span class="Delimiter">.</span>at<span class="Delimiter">(</span><span class="Constant">1</span><span class="Delimiter">))</span> && !is_mu_text<span class="Delimiter">(</span>inst<span class="Delimiter">.</span>ingredients<span class="Delimiter">.</span>at<span class="Delimiter">(</span><span class="Constant">1</span><span class="Delimiter">)))</span> <span class="Delimiter">{</span> -<span id="L181" class="LineNr">181 </span> <a href='003trace.cc.html#L178'>raise</a> << <a href='013update_operation.cc.html#L25'>maybe</a><span class="Delimiter">(</span>get<span class="Delimiter">(</span>Recipe<span class="Delimiter">,</span> r<span class="Delimiter">).</span>name<span class="Delimiter">)</span> << <span class="Constant">"'assert' requires a text as its second ingredient, but got '"</span> << inst<span class="Delimiter">.</span>ingredients<span class="Delimiter">.</span>at<span class="Delimiter">(</span><span class="Constant">1</span><span class="Delimiter">).</span>original_string << <span class="Constant">"'</span><span class="cSpecial">\n</span><span class="Constant">"</span> << <a href='003trace.cc.html#L195'>end</a><span class="Delimiter">();</span> +<span id="L181" class="LineNr">181 </span> <a href='003trace.cc.html#L176'>raise</a> << <a href='013update_operation.cc.html#L25'>maybe</a><span class="Delimiter">(</span>get<span class="Delimiter">(</span>Recipe<span class="Delimiter">,</span> r<span class="Delimiter">).</span>name<span class="Delimiter">)</span> << <span class="Constant">"'assert' requires a text as its second ingredient, but got '"</span> << inst<span class="Delimiter">.</span>ingredients<span class="Delimiter">.</span>at<span class="Delimiter">(</span><span class="Constant">1</span><span class="Delimiter">).</span>original_string << <span class="Constant">"'</span><span class="cSpecial">\n</span><span class="Constant">"</span> << <a href='003trace.cc.html#L193'>end</a><span class="Delimiter">();</span> <span id="L182" class="LineNr">182 </span> <span class="Identifier">break</span><span class="Delimiter">;</span> <span id="L183" class="LineNr">183 </span> <span class="Delimiter">}</span> <span id="L184" class="LineNr">184 </span> <span class="Identifier">break</span><span class="Delimiter">;</span> @@ -250,9 +250,9 @@ if ('onhashchange' in window) { <span id="L187" class="LineNr">187 </span><span class="Normal">case</span> ASSERT: <span class="Delimiter">{</span> <span id="L188" class="LineNr">188 </span> <span class="Normal">if</span> <span class="Delimiter">(</span>!ingredients<span class="Delimiter">.</span>at<span class="Delimiter">(</span><span class="Constant">0</span><span class="Delimiter">).</span>at<span class="Delimiter">(</span><span class="Constant">0</span><span class="Delimiter">))</span> <span class="Delimiter">{</span> <span id="L189" class="LineNr">189 </span> <span class="Normal">if</span> <span class="Delimiter">(</span><a href='014literal_string.cc.html#L126'>is_literal_text</a><span class="Delimiter">(</span>current_instruction<span class="Delimiter">().</span>ingredients<span class="Delimiter">.</span>at<span class="Delimiter">(</span><span class="Constant">1</span><span class="Delimiter">)))</span> -<span id="L190" class="LineNr">190 </span> <a href='003trace.cc.html#L178'>raise</a> << current_instruction<span class="Delimiter">().</span>ingredients<span class="Delimiter">.</span>at<span class="Delimiter">(</span><span class="Constant">1</span><span class="Delimiter">).</span>name << <span class="cSpecial">'\n'</span> << <a href='003trace.cc.html#L195'>end</a><span class="Delimiter">();</span> +<span id="L190" class="LineNr">190 </span> <a href='003trace.cc.html#L176'>raise</a> << current_instruction<span class="Delimiter">().</span>ingredients<span class="Delimiter">.</span>at<span class="Delimiter">(</span><span class="Constant">1</span><span class="Delimiter">).</span>name << <span class="cSpecial">'\n'</span> << <a href='003trace.cc.html#L193'>end</a><span class="Delimiter">();</span> <span id="L191" class="LineNr">191 </span> <span class="Normal">else</span> -<span id="L192" class="LineNr">192 </span> <a href='003trace.cc.html#L178'>raise</a> << <a href='038new_text.cc.html#L143'>read_mu_text</a><span class="Delimiter">(</span>ingredients<span class="Delimiter">.</span>at<span class="Delimiter">(</span><span class="Constant">1</span><span class="Delimiter">).</span>at<span class="Delimiter">(</span><span class="Constant">0</span><span class="Delimiter">))</span> << <span class="cSpecial">'\n'</span> << <a href='003trace.cc.html#L195'>end</a><span class="Delimiter">();</span> +<span id="L192" class="LineNr">192 </span> <a href='003trace.cc.html#L176'>raise</a> << <a href='038new_text.cc.html#L143'>read_mu_text</a><span class="Delimiter">(</span>ingredients<span class="Delimiter">.</span>at<span class="Delimiter">(</span><span class="Constant">1</span><span class="Delimiter">).</span>at<span class="Delimiter">(</span><span class="Constant">0</span><span class="Delimiter">))</span> << <span class="cSpecial">'\n'</span> << <a href='003trace.cc.html#L193'>end</a><span class="Delimiter">();</span> <span id="L193" class="LineNr">193 </span> <span class="Delimiter">}</span> <span id="L194" class="LineNr">194 </span> <span class="Identifier">break</span><span class="Delimiter">;</span> <span id="L195" class="LineNr">195 </span><span class="Delimiter">}</span> |