ops.h: update OP_ARYDUP instruction and rename to OP_ARYSPLAT.

Transforms the value of a splat inside a return statement (similar
to an array). For example, `return *nil` should return `nil.to_a`,
while `return *1` should return `[1]`
This commit is contained in:
fn ⌃ ⌥
2022-10-28 06:53:21 -07:00
parent 6ee4f845c6
commit 273fcbc347
5 changed files with 8 additions and 13 deletions
+2 -2
View File
@@ -476,8 +476,8 @@ codedump(mrb_state *mrb, const mrb_irep *irep)
printf("ARYPUSH\tR%d\t%d\t", a, b);
print_lv_a(mrb, irep, a);
break;
CASE(OP_ARYDUP, B):
printf("ARYDUP\tR%d\t", a);
CASE(OP_ARYSPLAT, B):
printf("ARYSPLAT\tR%d\t", a);
print_lv_a(mrb, irep, a);
break;
CASE(OP_AREF, BBB):