From 15433557812c1b8153fe3f238311ff808c8389b6 Mon Sep 17 00:00:00 2001 From: "Kartik K. Agaram" Date: Sat, 14 Mar 2015 22:29:09 -0700 Subject: 923 --- cpp/012run | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/cpp/012run b/cpp/012run index d2c22e44..0d102660 100644 --- a/cpp/012run +++ b/cpp/012run @@ -51,8 +51,7 @@ void run(recipe_number r) { void run(routine rr) { // #defines save us the trouble of updating aliases when dependent variables // change. -#define TOP_RECIPE Recipe[rr.calls.top().running_recipe] -#define instructions TOP_RECIPE.steps +#define instructions Recipe[rr.calls.top().running_recipe].steps while (!rr.calls.empty()) { while (rr.calls.top().pc >= instructions.size()) { rr.calls.pop(); @@ -61,7 +60,7 @@ void run(routine rr) { ++rr.calls.top().pc; } size_t& pc = rr.calls.top().pc; - trace("run") << "instruction " << TOP_RECIPE.name << '/' << pc; + trace("run") << "instruction " << Recipe[rr.calls.top().running_recipe].name << '/' << pc; switch (instructions[pc].operation) { // Primitive Recipe Implementations. case COPY: { @@ -77,7 +76,6 @@ void run(routine rr) { } ++pc; } -#undef TOP_RECIPE #undef instructions } -- cgit 1.4.1-2-gfad0