summaryrefslogtreecommitdiff
path: root/hash.c
diff options
context:
space:
mode:
authorBenoit Daloze <eregontp@gmail.com>2020-07-28 20:39:27 +0200
committerBenoit Daloze <eregontp@gmail.com>2020-07-29 18:09:53 +0200
commit241244739f2b721ac7aa0961bd90d904c5e3fff6 (patch)
treead0a6223575301c7e395e47e3183e940dcd0b162 /hash.c
parentf79dc8741f631f5572f4d2fa3cb7cad39b1356bb (diff)
Fix arity of Hash#to_proc [Bug #12671]
Notes
Notes: Merged: https://github.com/ruby/ruby/pull/3370
Diffstat (limited to 'hash.c')
-rw-r--r--hash.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/hash.c b/hash.c
index 358b78580b..f6581acfd2 100644
--- a/hash.c
+++ b/hash.c
@@ -5285,7 +5285,7 @@ hash_proc_call(RB_BLOCK_CALL_FUNC_ARGLIST(key, hash))
static VALUE
rb_hash_to_proc(VALUE hash)
{
- return rb_func_proc_new(hash_proc_call, hash);
+ return rb_func_lambda_new(hash_proc_call, hash, 1, 1);
}
static VALUE