about summary refs log tree commit diff stats
diff options
context:
space:
mode:
-rw-r--r--003trace.cc2
-rw-r--r--020run.cc4
-rw-r--r--059generic_recipe.cc6
3 files changed, 9 insertions, 3 deletions
diff --git a/003trace.cc b/003trace.cc
index 4a563fc6..fa333191 100644
--- a/003trace.cc
+++ b/003trace.cc
@@ -198,7 +198,7 @@ struct lease_tracer {
 
 #define START_TRACING_UNTIL_END_OF_SCOPE  lease_tracer leased_tracer;
 :(before "End Test Setup")
-START_TRACING_UNTIL_END_OF_SCOPE
+//? START_TRACING_UNTIL_END_OF_SCOPE
 
 :(before "End Includes")
 #define CHECK_TRACE_CONTENTS(...)  check_trace_contents(__FUNCTION__, __FILE__, __LINE__, __VA_ARGS__)
diff --git a/020run.cc b/020run.cc
index fad6a5b0..1a822be1 100644
--- a/020run.cc
+++ b/020run.cc
@@ -134,8 +134,8 @@ inline bool routine::completed() const {
 
 //: Step 1: load all .mu files with numeric prefixes (in order)
 :(before "End Load Recipes")
-//? Trace_file = "interactive";
-//? START_TRACING_UNTIL_END_OF_SCOPE;
+Trace_file = "interactive";
+START_TRACING_UNTIL_END_OF_SCOPE;
 load_permanently("core.mu");
 transform_all();
 
diff --git a/059generic_recipe.cc b/059generic_recipe.cc
index 64dbf6a1..e31a5d12 100644
--- a/059generic_recipe.cc
+++ b/059generic_recipe.cc
@@ -153,6 +153,12 @@ recipe_ordinal new_variant(recipe_ordinal exemplar, const instruction& inst) {
   map<string, string> mappings;  // weak references
   compute_type_ingredient_mappings(get(Recipe, exemplar), inst, mappings);
   replace_type_ingredients(new_recipe, mappings);
+  // redo all previous transforms in the new specialization, except for non-idempotent ones
+  // including this one in case there are new ambiguous calls in the specialization
+  for (long long int t = 0; t <= new_recipe.transformed_until; ++t) {
+    if (Transform.at(t) == insert_fragments) continue;  // not idempotent
+    (*Transform.at(t))(result);
+  }
   return result;
 }