merge revision(s) 40205: [Backport #8236]

* compile.c (iseq_compile_each): append keyword hash to argument array
	  to splat if needed.  [ruby-core:54094] [Bug #8236]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_0_0@40379 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
nagachika 2013-04-19 16:02:09 +00:00
parent 1ccf489ad5
commit a569165d3e
4 changed files with 32 additions and 1 deletions

View file

@ -4485,6 +4485,11 @@ iseq_compile_each(rb_iseq_t *iseq, LINK_ANCHOR *ret, NODE * node, int poped)
ADD_INSN2(args, line, getlocal, INT2FIX(idx), INT2FIX(lvar_level));
}
ADD_SEND(args, line, ID2SYM(id_core_hash_merge_ptr), INT2FIX(i * 2 + 1));
if (liseq->arg_rest != -1) {
ADD_INSN1(args, line, newarray, INT2FIX(1));
ADD_INSN (args, line, concatarray);
--argc;
}
}
}
}