about summary refs log tree commit diff stats
path: root/cpp/020run
diff options
context:
space:
mode:
Diffstat (limited to 'cpp/020run')
-rw-r--r--cpp/020run12
1 files changed, 6 insertions, 6 deletions
diff --git a/cpp/020run b/cpp/020run
index 3e993f95..a9afb460 100644
--- a/cpp/020run
+++ b/cpp/020run
@@ -1,4 +1,4 @@
-//: Once a recipe is loaded, we need to run it.
+//: Phase 3: Start running a loaded and transformed recipe.
 //:
 //: So far we've seen recipes as lists of instructions, and instructions point
 //: at other recipes. To kick things off mu needs to know how to run certain
@@ -101,7 +101,7 @@ inline bool done(routine& rr) {
 :(before "End Commandline Parsing")
 if (argc > 1) {
   for (int i = 1; i < argc; ++i) {
-    load(argv[i]);
+    load_and_transform(argv[i]);
   }
 }
 
@@ -118,14 +118,14 @@ if (!Run_tests) {
 }
 
 :(code)
-void load(string filename) {
+void load_and_transform(string filename) {
   ifstream fin(filename.c_str());
   if (!fin) {
     raise << "no such file " << filename << '\n';
     return;
   }
   fin >> std::noskipws;
-  add_recipes(fin);
+  load(fin);
   transform_all();
   fin.close();
   // freeze everything so it doesn't get cleared by tests
@@ -135,12 +135,12 @@ void load(string filename) {
 
 //:: On startup, load everything in core.mu
 :(before "End Load Recipes")
-load("core.mu");
+load_and_transform("core.mu");
 
 :(code)
 // helper for tests
 void run(string form) {
-  vector<recipe_number> tmp = add_recipes(form);
+  vector<recipe_number> tmp = load(form);
   transform_all();
   run(tmp.front());
 }