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 /024jump.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 '024jump.cc')
-rw-r--r-- | 024jump.cc | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/024jump.cc b/024jump.cc index 6278ffc2..57c4d3bb 100644 --- a/024jump.cc +++ b/024jump.cc @@ -16,7 +16,7 @@ put(Recipe_ordinal, "jump", JUMP); :(before "End Primitive Recipe Checks") case JUMP: { if (SIZE(inst.ingredients) != 1) { - raise << maybe(get(Recipe, r).name) << "'jump' requires exactly one ingredient, but got '" << to_original_string(inst) << "'\n" << end(); + raise << maybe(get(Recipe, r).name) << "'jump' requires exactly one ingredient, but got '" << inst.original_string << "'\n" << end(); break; } if (!is_literal(inst.ingredients.at(0))) { @@ -55,7 +55,7 @@ put(Recipe_ordinal, "jump-if", JUMP_IF); :(before "End Primitive Recipe Checks") case JUMP_IF: { if (SIZE(inst.ingredients) != 2) { - raise << maybe(get(Recipe, r).name) << "'jump-if' requires exactly two ingredients, but got '" << to_original_string(inst) << "'\n" << end(); + raise << maybe(get(Recipe, r).name) << "'jump-if' requires exactly two ingredients, but got '" << inst.original_string << "'\n" << end(); break; } if (!is_mu_scalar(inst.ingredients.at(0))) { @@ -108,7 +108,7 @@ put(Recipe_ordinal, "jump-unless", JUMP_UNLESS); :(before "End Primitive Recipe Checks") case JUMP_UNLESS: { if (SIZE(inst.ingredients) != 2) { - raise << maybe(get(Recipe, r).name) << "'jump-unless' requires exactly two ingredients, but got '" << to_original_string(inst) << "'\n" << end(); + raise << maybe(get(Recipe, r).name) << "'jump-unless' requires exactly two ingredients, but got '" << inst.original_string << "'\n" << end(); break; } if (!is_mu_scalar(inst.ingredients.at(0))) { |