diff options
author | Kartik K. Agaram <vc@akkartik.com> | 2015-07-29 15:55:05 -0700 |
---|---|---|
committer | Kartik K. Agaram <vc@akkartik.com> | 2015-07-29 15:55:05 -0700 |
commit | 9570363aec35e187e2395b1760a4b94e71580ac9 (patch) | |
tree | 5b0d9cf65b5d5a403ab29e88535ba158efb276fe /html/037recipe.cc.html | |
parent | b318b7fb127a2bdf3e394b315a45d339dc738447 (diff) | |
download | mu-9570363aec35e187e2395b1760a4b94e71580ac9.tar.gz |
1885
Diffstat (limited to 'html/037recipe.cc.html')
-rw-r--r-- | html/037recipe.cc.html | 17 |
1 files changed, 8 insertions, 9 deletions
diff --git a/html/037recipe.cc.html b/html/037recipe.cc.html index ce2f2798..e0d7a2c4 100644 --- a/html/037recipe.cc.html +++ b/html/037recipe.cc.html @@ -13,15 +13,14 @@ pre { white-space: pre-wrap; font-family: monospace; color: #eeeeee; background-color: #080808; } body { font-family: monospace; color: #eeeeee; background-color: #080808; } * { font-size: 1.05em; } +.traceContains { color: #008000; } .cSpecial { color: #008000; } .Constant { color: #00a0a0; } -.Normal { color: #eeeeee; background-color: #080808; padding-bottom: 1px; } -.CommentedCode { color: #6c6c6c; } .Comment { color: #9090ff; } .Delimiter { color: #a04060; } .Special { color: #ff6060; } +.CommentedCode { color: #6c6c6c; } .Identifier { color: #804000; } -.traceContains { color: #008000; } --> </style> @@ -39,7 +38,7 @@ body { font-family: monospace; color: #eeeeee; background-color: #080808; } <span class="Delimiter">:(scenario call_literal_recipe)</span> recipe main [ - <span class="Constant">1</span>:number<span class="Special"> <- </span>call f:recipe<span class="Delimiter">,</span> <span class="Constant">34</span>:literal + <span class="Constant">1</span>:number<span class="Special"> <- </span>call f:recipe<span class="Delimiter">,</span> <span class="Constant">34</span> ] recipe f [ <span class="Constant">2</span>:number<span class="Special"> <- </span>next-ingredient @@ -50,7 +49,7 @@ recipe f [ <span class="Delimiter">:(scenario call_variable)</span> recipe main [ <span class="Constant">1</span>:recipe-ordinal<span class="Special"> <- </span>copy f:recipe - <span class="Constant">2</span>:number<span class="Special"> <- </span>call <span class="Constant">1</span>:recipe-ordinal<span class="Delimiter">,</span> <span class="Constant">34</span>:literal + <span class="Constant">2</span>:number<span class="Special"> <- </span>call <span class="Constant">1</span>:recipe-ordinal<span class="Delimiter">,</span> <span class="Constant">34</span> ] recipe f [ <span class="Constant">3</span>:number<span class="Special"> <- </span>next-ingredient @@ -67,7 +66,7 @@ type_ordinal recipe_ordinal = Type_ordinal[<span class="Constant">"recipe-o Type[recipe_ordinal]<span class="Delimiter">.</span>name = <span class="Constant">"recipe-ordinal"</span><span class="Delimiter">;</span> <span class="Delimiter">:(before "End Reagent-parsing Exceptions")</span> -<span class="Normal">if</span> <span class="Delimiter">(</span>!r<span class="Delimiter">.</span>properties<span class="Delimiter">.</span>at<span class="Delimiter">(</span><span class="Constant">0</span><span class="Delimiter">).</span>second<span class="Delimiter">.</span>empty<span class="Delimiter">()</span> && r<span class="Delimiter">.</span>properties<span class="Delimiter">.</span>at<span class="Delimiter">(</span><span class="Constant">0</span><span class="Delimiter">).</span>second<span class="Delimiter">.</span>at<span class="Delimiter">(</span><span class="Constant">0</span><span class="Delimiter">)</span> == <span class="Constant">"recipe"</span><span class="Delimiter">)</span> <span class="Delimiter">{</span> +if <span class="Delimiter">(</span>!r<span class="Delimiter">.</span>properties<span class="Delimiter">.</span>at<span class="Delimiter">(</span><span class="Constant">0</span><span class="Delimiter">).</span>second<span class="Delimiter">.</span>empty<span class="Delimiter">()</span> && r<span class="Delimiter">.</span>properties<span class="Delimiter">.</span>at<span class="Delimiter">(</span><span class="Constant">0</span><span class="Delimiter">).</span>second<span class="Delimiter">.</span>at<span class="Delimiter">(</span><span class="Constant">0</span><span class="Delimiter">)</span> == <span class="Constant">"recipe"</span><span class="Delimiter">)</span> <span class="Delimiter">{</span> r<span class="Delimiter">.</span>set_value<span class="Delimiter">(</span>Recipe_ordinal[r<span class="Delimiter">.</span>name]<span class="Delimiter">);</span> <span class="Identifier">return</span><span class="Delimiter">;</span> <span class="Delimiter">}</span> @@ -77,13 +76,13 @@ CALL<span class="Delimiter">,</span> <span class="Delimiter">:(before "End Primitive Recipe Numbers")</span> Recipe_ordinal[<span class="Constant">"call"</span>] = CALL<span class="Delimiter">;</span> <span class="Delimiter">:(before "End Primitive Recipe Implementations")</span> -<span class="Normal">case</span> CALL: <span class="Delimiter">{</span> - <span class="Normal">if</span> <span class="Delimiter">(</span>ingredients<span class="Delimiter">.</span>empty<span class="Delimiter">())</span> <span class="Delimiter">{</span> +case CALL: <span class="Delimiter">{</span> + if <span class="Delimiter">(</span>ingredients<span class="Delimiter">.</span>empty<span class="Delimiter">())</span> <span class="Delimiter">{</span> raise << current_recipe_name<span class="Delimiter">()</span> << <span class="Constant">": 'call' requires at least one ingredient (the recipe to call)</span><span class="cSpecial">\n</span><span class="Constant">"</span> << end<span class="Delimiter">();</span> <span class="Identifier">break</span><span class="Delimiter">;</span> <span class="Delimiter">}</span> <span class="Comment">// Begin Call</span> - <span class="Normal">if</span> <span class="Delimiter">(</span>!scalar<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> + if <span class="Delimiter">(</span>!scalar<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> raise << current_recipe_name<span class="Delimiter">()</span> << <span class="Constant">": first ingredient of 'call' should be a recipe, but got "</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>original_string << <span class="cSpecial">'\n'</span> << end<span class="Delimiter">();</span> <span class="Identifier">break</span><span class="Delimiter">;</span> <span class="Delimiter">}</span> |