about summary refs log tree commit diff stats
path: root/036call_reply.cc
diff options
context:
space:
mode:
authorKartik K. Agaram <vc@akkartik.com>2016-03-21 02:25:52 -0700
committerKartik K. Agaram <vc@akkartik.com>2016-03-21 02:25:52 -0700
commitacc4792d2f7c787aad064876a1eb2d00bdf076b2 (patch)
tree22aaf0d8ff820082d66008311607e639c2d48989 /036call_reply.cc
parentdad3bedd1ca78162f87a235c10b036a06492a5f5 (diff)
downloadmu-acc4792d2f7c787aad064876a1eb2d00bdf076b2.tar.gz
2803
Show more thorough information about instructions in the trace, but keep
the original form in error messages.
Diffstat (limited to '036call_reply.cc')
-rw-r--r--036call_reply.cc6
1 files changed, 3 insertions, 3 deletions
diff --git a/036call_reply.cc b/036call_reply.cc
index f0f37137..9f6718c2 100644
--- a/036call_reply.cc
+++ b/036call_reply.cc
@@ -98,16 +98,16 @@ void check_types_of_reply_instructions(recipe_ordinal r) {
         if (has_property(reply_inst.ingredients.at(i), "same-as-ingredient")) {
           string_tree* tmp = property(reply_inst.ingredients.at(i), "same-as-ingredient");
           if (!tmp || tmp->right) {
-            raise << maybe(caller.name) << "'same-as-ingredient' metadata should take exactly one value in " << to_string(reply_inst) << '\n' << end();
+            raise << maybe(caller.name) << "'same-as-ingredient' metadata should take exactly one value in " << to_original_string(reply_inst) << '\n' << end();
             goto finish_reply_check;
           }
           int ingredient_index = to_integer(tmp->value);
           if (ingredient_index >= SIZE(caller_instruction.ingredients)) {
-            raise << maybe(caller.name) << "too few ingredients in '" << to_string(caller_instruction) << "'\n" << end();
+            raise << maybe(caller.name) << "too few ingredients in '" << to_original_string(caller_instruction) << "'\n" << end();
             goto finish_reply_check;
           }
           if (!is_dummy(caller_instruction.products.at(i)) && !is_literal(caller_instruction.ingredients.at(ingredient_index)) && caller_instruction.products.at(i).name != caller_instruction.ingredients.at(ingredient_index).name) {
-            raise << maybe(caller.name) << "'" << to_string(caller_instruction) << "' should write to " << caller_instruction.ingredients.at(ingredient_index).original_string << " rather than " << caller_instruction.products.at(i).original_string << '\n' << end();
+            raise << maybe(caller.name) << "'" << to_original_string(caller_instruction) << "' should write to " << caller_instruction.ingredients.at(ingredient_index).original_string << " rather than " << caller_instruction.products.at(i).original_string << '\n' << end();
           }
         }
       }