diff options
-rw-r--r-- | html/013update_operation.cc.html | 11 | ||||
-rw-r--r-- | html/070table.mu.html | 11 | ||||
-rw-r--r-- | html/071recipe.cc.html | 9 |
3 files changed, 23 insertions, 8 deletions
diff --git a/html/013update_operation.cc.html b/html/013update_operation.cc.html index 132553c4..7dd7e69f 100644 --- a/html/013update_operation.cc.html +++ b/html/013update_operation.cc.html @@ -14,6 +14,9 @@ pre { white-space: pre-wrap; font-family: monospace; color: #eeeeee; background- body { font-size: 12pt; font-family: monospace; color: #eeeeee; background-color: #080808; } * { font-size: 12pt; font-size: 1em; } .Constant { color: #00a0a0; } +.Special { color: #c00000; } +.muRecipe { color: #ff8700; } +.traceContains { color: #008000; } .Comment { color: #9090ff; } .Delimiter { color: #800080; } .cSpecial { color: #008000; } @@ -58,6 +61,14 @@ Transform<span class="Delimiter">.</span>push_back<span class="Delimiter">(</spa string maybe<span class="Delimiter">(</span>string s<span class="Delimiter">)</span> <span class="Delimiter">{</span> <span class="Identifier">return</span> s + <span class="Constant">": "</span><span class="Delimiter">;</span> <span class="Delimiter">}</span> + +<span class="Delimiter">:(scenarios transform)</span> +<span class="Delimiter">:(scenario missing_arrow)</span> +<span class="Special">% Hide_errors = true;</span> +<span class="muRecipe">def</span> main [ + <span class="Constant">1</span>:number <span class="Delimiter">,</span> copy <span class="Constant">0</span> <span class="Comment"># typo: ',' instead of '<-'</span> +] +<span class="traceContains">+error: main: instruction '1:number' has no recipe</span> </pre> </body> </html> diff --git a/html/070table.mu.html b/html/070table.mu.html index 91999624..61e1466b 100644 --- a/html/070table.mu.html +++ b/html/070table.mu.html @@ -13,9 +13,9 @@ pre { white-space: pre-wrap; font-family: monospace; color: #eeeeee; background-color: #080808; } body { font-size: 12pt; font-family: monospace; color: #eeeeee; background-color: #080808; } * { font-size: 12pt; font-size: 1em; } -.Delimiter { color: #800080; } -.muControl { color: #c0a020; } .muData { color: #ffff00; } +.muControl { color: #c0a020; } +.Delimiter { color: #800080; } .Comment { color: #9090ff; } .Constant { color: #00a0a0; } .Special { color: #c00000; } @@ -49,11 +49,10 @@ body { font-size: 12pt; font-family: monospace; color: #eeeeee; background-color <span class="muScenario">scenario</span> table-read-write-non-integer [ <span class="Constant">local-scope</span> - key:text <span class="Special"><-</span> new <span class="Constant">[abc def]</span> - <span class="Delimiter">{</span>tab: (address table text number)<span class="Delimiter">}</span> <span class="Special"><-</span> new-table<span class="Constant"> 30</span> + tab:&:table:text:num <span class="Special"><-</span> new-table<span class="Constant"> 30</span> run [ - put-index tab, key,<span class="Constant"> 34</span> - 1:num/<span class="Special">raw</span> <span class="Special"><-</span> index tab, key + put-index tab, <span class="Constant">[abc def]</span>,<span class="Constant"> 34</span> + 1:num/<span class="Special">raw</span> <span class="Special"><-</span> index tab, <span class="Constant">[abc def]</span> ] memory-should-contain [ <span class="Constant"> 1</span> <span class="Special"><-</span><span class="Constant"> 34</span> diff --git a/html/071recipe.cc.html b/html/071recipe.cc.html index 7db245d8..b5ac57d7 100644 --- a/html/071recipe.cc.html +++ b/html/071recipe.cc.html @@ -196,9 +196,10 @@ Transform<span class="Delimiter">.</span>push_back<span class="Delimiter">(</spa <span class="Normal">const</span> recipe& caller = get<span class="Delimiter">(</span>Recipe<span class="Delimiter">,</span> r<span class="Delimiter">);</span> <span class="Normal">for</span> <span class="Delimiter">(</span><span class="Normal">int</span> i = <span class="Constant">0</span><span class="Delimiter">;</span> i < SIZE<span class="Delimiter">(</span>caller<span class="Delimiter">.</span>steps<span class="Delimiter">);</span> ++i<span class="Delimiter">)</span> <span class="Delimiter">{</span> <span class="Normal">const</span> instruction& inst = caller<span class="Delimiter">.</span>steps<span class="Delimiter">.</span>at<span class="Delimiter">(</span>i<span class="Delimiter">);</span> - <span class="Normal">if</span> <span class="Delimiter">(</span>inst<span class="Delimiter">.</span>ingredients<span class="Delimiter">.</span>empty<span class="Delimiter">())</span> <span class="Identifier">continue</span><span class="Delimiter">;</span> <span class="Comment">// if indirect call, error raised above</span> + <span class="Normal">if</span> <span class="Delimiter">(</span>!is_indirect_call<span class="Delimiter">(</span>inst<span class="Delimiter">.</span>operation<span class="Delimiter">))</span> <span class="Identifier">continue</span><span class="Delimiter">;</span> + <span class="Normal">if</span> <span class="Delimiter">(</span>inst<span class="Delimiter">.</span>ingredients<span class="Delimiter">.</span>empty<span class="Delimiter">())</span> <span class="Identifier">continue</span><span class="Delimiter">;</span> <span class="Comment">// error raised above</span> <span class="Normal">const</span> reagent& callee = 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="Normal">if</span> <span class="Delimiter">(</span>!is_mu_recipe<span class="Delimiter">(</span>callee<span class="Delimiter">))</span> <span class="Identifier">continue</span><span class="Delimiter">;</span> <span class="Comment">// if indirect call, error raised above</span> + <span class="Normal">if</span> <span class="Delimiter">(</span>!is_mu_recipe<span class="Delimiter">(</span>callee<span class="Delimiter">))</span> <span class="Identifier">continue</span><span class="Delimiter">;</span> <span class="Comment">// error raised above</span> <span class="Normal">const</span> recipe callee_header = is_literal<span class="Delimiter">(</span>callee<span class="Delimiter">)</span> ? get<span class="Delimiter">(</span>Recipe<span class="Delimiter">,</span> callee<span class="Delimiter">.</span>value<span class="Delimiter">)</span> : from_reagent<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="Normal">if</span> <span class="Delimiter">(</span>!callee_header<span class="Delimiter">.</span>has_header<span class="Delimiter">)</span> <span class="Identifier">continue</span><span class="Delimiter">;</span> <span class="Normal">if</span> <span class="Delimiter">(</span>is_indirect_call_with_ingredients<span class="Delimiter">(</span>inst<span class="Delimiter">.</span>operation<span class="Delimiter">))</span> <span class="Delimiter">{</span> @@ -217,6 +218,10 @@ Transform<span class="Delimiter">.</span>push_back<span class="Delimiter">(</spa <span class="Delimiter">}</span> <span class="Delimiter">}</span> +<span class="Normal">bool</span> is_indirect_call<span class="Delimiter">(</span><span class="Normal">const</span> recipe_ordinal r<span class="Delimiter">)</span> <span class="Delimiter">{</span> + <span class="Identifier">return</span> is_indirect_call_with_ingredients<span class="Delimiter">(</span>r<span class="Delimiter">)</span> || is_indirect_call_with_products<span class="Delimiter">(</span>r<span class="Delimiter">);</span> +<span class="Delimiter">}</span> + <span class="Normal">bool</span> is_indirect_call_with_ingredients<span class="Delimiter">(</span><span class="Normal">const</span> recipe_ordinal r<span class="Delimiter">)</span> <span class="Delimiter">{</span> <span class="Normal">if</span> <span class="Delimiter">(</span>r == CALL<span class="Delimiter">)</span> <span class="Identifier">return</span> <span class="Constant">true</span><span class="Delimiter">;</span> <span class="Comment">// End is_indirect_call_with_ingredients Special-cases</span> |