about summary refs log tree commit diff stats
path: root/html/075scenario_keyboard.cc.html
diff options
context:
space:
mode:
authorKartik K. Agaram <vc@akkartik.com>2015-05-25 22:27:19 -0700
committerKartik K. Agaram <vc@akkartik.com>2015-05-25 22:27:19 -0700
commitc5ffb6e1cc9c5ff880d037c53b8ebc8562be0008 (patch)
tree2d05d987ec3c81bfbb0c1f598966d9d1b16e9b1f /html/075scenario_keyboard.cc.html
parentb2757892d553352feb59d70b1e7241ccdafa6905 (diff)
downloadmu-c5ffb6e1cc9c5ff880d037c53b8ebc8562be0008.tar.gz
1459
Diffstat (limited to 'html/075scenario_keyboard.cc.html')
-rw-r--r--html/075scenario_keyboard.cc.html10
1 files changed, 8 insertions, 2 deletions
diff --git a/html/075scenario_keyboard.cc.html b/html/075scenario_keyboard.cc.html
index 2a612899..744b8bc8 100644
--- a/html/075scenario_keyboard.cc.html
+++ b/html/075scenario_keyboard.cc.html
@@ -2,7 +2,7 @@
 <html>
 <head>
 <meta http-equiv="content-type" content="text/html; charset=UTF-8">
-<title>~/Desktop/s/mu/075scenario_keyboard.cc</title>
+<title>075scenario_keyboard.cc</title>
 <meta name="Generator" content="Vim/7.4">
 <meta name="plugin-version" content="vim7.4_v1">
 <meta name="syntax" content="cpp">
@@ -17,6 +17,7 @@ body { font-family: monospace; color: #d0d0d0; background-color: #000000; }
 .Comment { color: #8080ff; }
 .Delimiter { color: #c000c0; }
 .Special { color: #ff6060; }
+.Identifier { color: #008080; }
 -->
 </style>
 
@@ -56,10 +57,14 @@ scenario keyboard-in-scenario [
 ]
 
 <span class="Delimiter">:(before &quot;End Scenario Globals&quot;)</span>
-const size_t KEYBOARD = Next_predefined_global_for_scenarios++<span class="Delimiter">;</span>
+const long long int KEYBOARD = Next_predefined_global_for_scenarios++<span class="Delimiter">;</span>
 <span class="Delimiter">:(before &quot;End Predefined Scenario Locals In Run&quot;)</span>
 Name[tmp_recipe<span class="Delimiter">.</span>at<span class="Delimiter">(</span><span class="Constant">0</span><span class="Delimiter">)</span>][<span class="Constant">&quot;keyboard&quot;</span>] = KEYBOARD<span class="Delimiter">;</span>
 
+<span class="Comment">//: allow naming just for 'keyword'</span>
+<span class="Delimiter">:(before &quot;End is_special_name Cases&quot;)</span>
+if <span class="Delimiter">(</span>s == <span class="Constant">&quot;keyboard&quot;</span><span class="Delimiter">)</span> <span class="Identifier">return</span> <span class="Constant">true</span><span class="Delimiter">;</span>
+
 <span class="Delimiter">:(before &quot;End Rewrite Instruction(curr)&quot;)</span>
 <span class="Comment">// rewrite `assume-keyboard string` to</span>
 <span class="Comment">//   ```</span>
@@ -76,6 +81,7 @@ if <span class="Delimiter">(</span>curr<span class="Delimiter">.</span>name == <
   <span class="Comment">// leave second instruction in curr</span>
   curr<span class="Delimiter">.</span>clear<span class="Delimiter">();</span>
   curr<span class="Delimiter">.</span>operation = Recipe_number[<span class="Constant">&quot;init-fake-keyboard&quot;</span>]<span class="Delimiter">;</span>
+  curr<span class="Delimiter">.</span>name = <span class="Constant">&quot;init-fake-keyboard&quot;</span><span class="Delimiter">;</span>
   assert<span class="Delimiter">(</span>curr<span class="Delimiter">.</span>ingredients<span class="Delimiter">.</span>empty<span class="Delimiter">());</span>
   curr<span class="Delimiter">.</span>ingredients<span class="Delimiter">.</span>push_back<span class="Delimiter">(</span>reagent<span class="Delimiter">(</span><span class="Constant">&quot;keyboard:address&quot;</span><span class="Delimiter">));</span>
   curr<span class="Delimiter">.</span>ingredients<span class="Delimiter">.</span>at<span class="Delimiter">(</span><span class="Constant">0</span><span class="Delimiter">).</span>set_value<span class="Delimiter">(</span>KEYBOARD<span class="Delimiter">);</span>