Rename `OP_JUW` instruction to `OP_JMPUW`.
MODIFY
doc/opcode.md
doc/opcode.md
@@ -62,7 +62,7 @@ sign) of operands.
| OP_JMPIF | BS | if R(a) pc=b |
| OP_JMPNOT | BS | if !R(a) pc=b |
| OP_JMPNIL | BS | if R(a)==nil pc=b |
-| OP_JUW | S | unwind_and_jump_to(a) |
+| OP_JMPUW | S | unwind_and_jump_to(a) |
| OP_EXCEPT | B | R(a) = exc |
| OP_RESCUE | BB | R(b) = R(a).isa?(R(b)) |
| OP_RAISEIF | B | raise(R(a)) if R(a) |

MODIFY
include/mruby/ops.h
include/mruby/ops.h
@@ -49,7 +49,7 @@ OPCODE(JMP, S) /* pc=a */
OPCODE(JMPIF, BS) /* if R(a) pc=b */
OPCODE(JMPNOT, BS) /* if !R(a) pc=b */
OPCODE(JMPNIL, BS) /* if R(a)==nil pc=b */
-OPCODE(JUW, S) /* unwind_and_jump_to(a) */
+OPCODE(JMPUW, S) /* unwind_and_jump_to(a) */
OPCODE(EXCEPT, B) /* R(a) = exc */
OPCODE(RESCUE, BB) /* R(b) = R(a).isa?(R(b)) */
OPCODE(RAISEIF, B) /* raise(R(a)) if R(a) */

MODIFY
mrbgems/mruby-compiler/core/codegen.c
mrbgems/mruby-compiler/core/codegen.c
@@ -2299,7 +2299,7 @@ codegen(codegen_scope *s, node *tree, int val)
}
else if (s->loop->type == LOOP_NORMAL) {
codegen(s, tree, NOVAL);
- genjmp(s, OP_JUW, s->loop->pc0);
+ genjmp(s, OP_JMPUW, s->loop->pc0);
}
else {
if (tree) {
@@ -2319,7 +2319,7 @@ codegen(codegen_scope *s, node *tree, int val)
raise_error(s, "unexpected redo");
}
else {
- genjmp(s, OP_JUW, s->loop->pc2);
+ genjmp(s, OP_JMPUW, s->loop->pc2);
}
if (val) push();
break;
@@ -2336,7 +2336,7 @@ codegen(codegen_scope *s, node *tree, int val)
raise_error(s, msg);
}
else {
- genjmp(s, OP_JUW, lp->pc0);
+ genjmp(s, OP_JMPUW, lp->pc0);
}
if (val) push();
}
@@ -3163,7 +3163,7 @@ loop_break(codegen_scope *s, node *tree)
if (tree) {
gen_move(s, loop->acc, cursp(), 0);
}
- tmp = genjmp(s, OP_JUW, loop->pc3);
+ tmp = genjmp(s, OP_JMPUW, loop->pc3);
loop->pc3 = tmp;
}
else {

MODIFY
src/codedump.c
src/codedump.c
@@ -261,8 +261,8 @@ codedump(mrb_state *mrb, const mrb_irep *irep)
CASE(OP_JMP, S);
printf("OP_JMP\t\t%03d\n", a);
break;
- CASE(OP_JUW, S);
- printf("OP_JUW\t\t%03d\n", a);
+ CASE(OP_JMPUW, S);
+ printf("OP_JMPUW\t\t%03d\n", a);
break;
CASE(OP_JMPIF, BS);
printf("OP_JMPIF\tR%d\t%03d\t", a, b);

MODIFY
src/vm.c
src/vm.c
@@ -1298,7 +1298,7 @@ RETRY_TRY_BLOCK:
NEXT;
}
- CASE(OP_JUW, S) {
+ CASE(OP_JMPUW, S) {
CHECKPOINT_RESTORE(RBREAK_TAG_JUMP) {
struct RBreak *brk = (struct RBreak*)mrb->exc;
mrb_value target = mrb_break_value_get(brk);

Rename `OP_JUW` instruction to `OP_JMPUW`.