diff options
author | Kartik K. Agaram <vc@akkartik.com> | 2016-07-21 19:22:03 -0700 |
---|---|---|
committer | Kartik K. Agaram <vc@akkartik.com> | 2016-07-21 19:22:03 -0700 |
commit | 8d72e5652147a0218f36757fd9171f3f2beda887 (patch) | |
tree | b95edd6bb86f7d421327d2f436e0c2d375cb795d /027call_ingredient.cc | |
parent | fc19980d91e306df87b308d0c2875a2dcaf4b5c7 (diff) | |
download | mu-8d72e5652147a0218f36757fd9171f3f2beda887.tar.gz |
3120
Always show instruction before any transforms in error messages. This is likely going to make some errors unclear because they *need* to show the original instruction. But if we don't have tests for those situations did they ever really work?
Diffstat (limited to '027call_ingredient.cc')
-rw-r--r-- | 027call_ingredient.cc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/027call_ingredient.cc b/027call_ingredient.cc index 1f3b26e8..9e98cdc2 100644 --- a/027call_ingredient.cc +++ b/027call_ingredient.cc @@ -42,7 +42,7 @@ put(Recipe_ordinal, "next-ingredient", NEXT_INGREDIENT); :(before "End Primitive Recipe Checks") case NEXT_INGREDIENT: { if (!inst.ingredients.empty()) { - raise << maybe(get(Recipe, r).name) << "'next-ingredient' didn't expect any ingredients in '" << to_original_string(inst) << "'\n" << end(); + raise << maybe(get(Recipe, r).name) << "'next-ingredient' didn't expect any ingredients in '" << inst.original_string << "'\n" << end(); break; } break; @@ -141,7 +141,7 @@ put(Recipe_ordinal, "ingredient", INGREDIENT); :(before "End Primitive Recipe Checks") case INGREDIENT: { if (SIZE(inst.ingredients) != 1) { - raise << maybe(get(Recipe, r).name) << "'ingredient' expects exactly one ingredient, but got '" << to_original_string(inst) << "'\n" << end(); + raise << maybe(get(Recipe, r).name) << "'ingredient' expects exactly one ingredient, but got '" << inst.original_string << "'\n" << end(); break; } if (!is_literal(inst.ingredients.at(0)) && !is_mu_number(inst.ingredients.at(0))) { |