about summary refs log tree commit diff stats
path: root/043space.cc
diff options
context:
space:
mode:
authorKartik K. Agaram <vc@akkartik.com>2017-04-27 09:07:53 -0700
committerKartik K. Agaram <vc@akkartik.com>2017-04-27 09:07:53 -0700
commitb8263692a6f2865482abbc21eae5a4e5163ab725 (patch)
treeb1b938d4a83cf2b420001c9188194a5800d12eb2 /043space.cc
parentf6645643953eeb0a493d258759a4421505d13539 (diff)
downloadmu-b8263692a6f2865482abbc21eae5a4e5163ab725.tar.gz
3841
Use the real original instruction in error messages.
Thanks Ella Couch.
Diffstat (limited to '043space.cc')
-rw-r--r--043space.cc4
1 files changed, 2 insertions, 2 deletions
diff --git a/043space.cc b/043space.cc
index 770871c1..0cd16151 100644
--- a/043space.cc
+++ b/043space.cc
@@ -62,7 +62,7 @@ void absolutize(reagent& x) {
   if (is_raw(x) || is_dummy(x)) return;
   if (x.name == "default-space") return;
   if (!x.initialized)
-    raise << to_original_string(current_instruction()) << ": reagent not initialized: '" << x.original_string << "'\n" << end();
+    raise << current_instruction().original_string << ": reagent not initialized: '" << x.original_string << "'\n" << end();
   x.set_value(address(x.value, space_base(x)));
   x.properties.push_back(pair<string, string_tree*>("raw", NULL));
   assert(is_raw(x));
@@ -311,7 +311,7 @@ bool caller_uses_product(int product_index) {
 
 void rewrite_default_space_instruction(instruction& curr) {
   if (!curr.ingredients.empty())
-    raise << to_original_string(curr) << " can't take any ingredients\n" << end();
+    raise << "'" << curr.original_string << "' can't take any ingredients\n" << end();
   curr.name = "new";
   curr.ingredients.push_back(reagent("location:type"));
   curr.ingredients.push_back(reagent("number-of-locals:literal"));