codegen.c: generate `OP_HASH` in `gen_hash()` if `limit` exceeds.
That means when `limit` is `0` it should always generate a hash.
MODIFY
mrbgems/mruby-compiler/core/codegen.c
mrbgems/mruby-compiler/core/codegen.c
@@ -1643,6 +1643,12 @@ gen_hash(codegen_scope *s, node *tree, int val, int limit)
len = 0;
}
}
+ if (val && len > limit) {
+ pop_n(len*2);
+ genop_2(s, OP_HASH, cursp(), len);
+ push();
+ return -1;
+ }
if (update) {
if (val && len > 0) {
pop_n(len*2+1);

codegen.c: generate `OP_HASH` in `gen_hash()` if `limit` exceeds.

That means when `limit` is `0` it should always generate a hash.