about summary refs log tree commit diff stats
path: root/033exclusive_container.cc
diff options
context:
space:
mode:
authorKartik K. Agaram <vc@akkartik.com>2017-05-26 16:43:18 -0700
committerKartik K. Agaram <vc@akkartik.com>2017-05-26 17:36:16 -0700
commit2b25071710656d7a755c2f66c99734cd7990d1ba (patch)
treef4e3a83d6397343c7c225a354f4f2c837aef8190 /033exclusive_container.cc
parent5e320aa049bc1d5ad78eec23be0127f4a8d6ec3d (diff)
downloadmu-2b25071710656d7a755c2f66c99734cd7990d1ba.tar.gz
3877
Diffstat (limited to '033exclusive_container.cc')
-rw-r--r--033exclusive_container.cc12
1 files changed, 6 insertions, 6 deletions
diff --git a/033exclusive_container.cc b/033exclusive_container.cc
index 6eac8f47..eee16643 100644
--- a/033exclusive_container.cc
+++ b/033exclusive_container.cc
@@ -100,7 +100,7 @@ put(Recipe_ordinal, "maybe-convert", MAYBE_CONVERT);
 case MAYBE_CONVERT: {
   const recipe& caller = get(Recipe, r);
   if (SIZE(inst.ingredients) != 2) {
-    raise << maybe(caller.name) << "'maybe-convert' expects exactly 2 ingredients in '" << inst.original_string << "'\n" << end();
+    raise << maybe(caller.name) << "'maybe-convert' expects exactly 2 ingredients in '" << to_original_string(inst) << "'\n" << end();
     break;
   }
   reagent/*copy*/ base = inst.ingredients.at(0);
@@ -121,7 +121,7 @@ case MAYBE_CONVERT: {
   }
   if (inst.products.empty()) break;
   if (SIZE(inst.products) != 2) {
-    raise << maybe(caller.name) << "'maybe-convert' expects exactly 2 products in '" << inst.original_string << "'\n" << end();
+    raise << maybe(caller.name) << "'maybe-convert' expects exactly 2 products in '" << to_original_string(inst) << "'\n" << end();
     break;
   }
   reagent/*copy*/ product = inst.products.at(0);
@@ -129,7 +129,7 @@ case MAYBE_CONVERT: {
   reagent& offset = inst.ingredients.at(1);
   populate_value(offset);
   if (offset.value >= SIZE(get(Type, base_type->value).elements)) {
-    raise << maybe(caller.name) << "invalid tag " << offset.value << " in '" << inst.original_string << '\n' << end();
+    raise << maybe(caller.name) << "invalid tag " << offset.value << " in '" << to_original_string(inst) << '\n' << end();
     break;
   }
   const reagent& variant = variant_type(base, offset.value);
@@ -151,7 +151,7 @@ case MAYBE_CONVERT: {
   // Update MAYBE_CONVERT base in Run
   int base_address = base.value;
   if (base_address == 0) {
-    raise << maybe(current_recipe_name()) << "tried to access location 0 in '" << current_instruction().original_string << "'\n" << end();
+    raise << maybe(current_recipe_name()) << "tried to access location 0 in '" << to_original_string(current_instruction()) << "'\n" << end();
     break;
   }
   int tag = current_instruction().ingredients.at(1).value;
@@ -322,13 +322,13 @@ case EXCLUSIVE_CONTAINER: {
   if (types_strictly_match(container, inst.ingredients.at(ingredient_index)))
     return;
   if (!is_literal(ingredients.at(ingredient_index))) {
-    raise << maybe(caller.name) << "ingredient " << ingredient_index << " of 'merge' should be a literal, for the tag of exclusive-container '" << container_info.name << "' in '" << inst.original_string << "'\n" << end();
+    raise << maybe(caller.name) << "ingredient " << ingredient_index << " of 'merge' should be a literal, for the tag of exclusive-container '" << container_info.name << "' in '" << to_original_string(inst) << "'\n" << end();
     return;
   }
   reagent/*copy*/ ingredient = ingredients.at(ingredient_index);  // unnecessary copy just to keep this function from modifying caller
   populate_value(ingredient);
   if (ingredient.value >= SIZE(container_info.elements)) {
-    raise << maybe(caller.name) << "invalid tag at " << ingredient_index << " for '" << container_info.name << "' in '" << inst.original_string << "'\n" << end();
+    raise << maybe(caller.name) << "invalid tag at " << ingredient_index << " for '" << container_info.name << "' in '" << to_original_string(inst) << "'\n" << end();
     return;
   }
   const reagent& variant = variant_type(container, ingredient.value);