about summary refs log tree commit diff stats
path: root/085scenario_console.cc
diff options
context:
space:
mode:
authorKartik K. Agaram <vc@akkartik.com>2016-10-15 21:12:30 -0700
committerKartik K. Agaram <vc@akkartik.com>2016-10-15 21:12:30 -0700
commit30c90fc4c79f254c41b4c3ee7dfb3cc505179438 (patch)
treeb3eb2313bb200c3d23a1c0dda9ba8cdb7a8dba44 /085scenario_console.cc
parent392249a76da19cae798998dda198fbe59fbee905 (diff)
downloadmu-30c90fc4c79f254c41b4c3ee7dfb3cc505179438.tar.gz
3502
Better implementation of commit 3445: not requiring types for special
variables in scenarios. It turned out that it wasn't working anytime we
needed to call 'get' on a special variable inside a scenario. After
moving that work to an earlier transform we can now use 'filesystem'
without a type inside scenarios.
Diffstat (limited to '085scenario_console.cc')
-rw-r--r--085scenario_console.cc7
1 files changed, 2 insertions, 5 deletions
diff --git a/085scenario_console.cc b/085scenario_console.cc
index 3c446a3b..24ffebed 100644
--- a/085scenario_console.cc
+++ b/085scenario_console.cc
@@ -187,12 +187,9 @@ void initialize_key_names() {
   Key["escape"] = TB_KEY_ESC;
 }
 
-:(after "Begin transform_names Ingredient Special-cases(ingredient, inst, caller)")
+:(after "Begin check_or_set_invalid_types(r)")
 if (is_scenario(caller))
-  initialize_special_name(ingredient);
-:(after "Begin transform_names Product Special-cases(product, inst, caller)")
-if (is_scenario(caller))
-  initialize_special_name(product);
+  initialize_special_name(r);
 :(code)
 bool is_scenario(const recipe& caller) {
   return starts_with(caller.name, "scenario_");