summaryrefslogtreecommitdiff
path: root/enum.c
diff options
context:
space:
mode:
authorNobuyoshi Nakada <nobu@ruby-lang.org>2020-07-24 21:08:50 +0900
committerNobuyoshi Nakada <nobu@ruby-lang.org>2020-07-24 21:08:50 +0900
commit3ead2770a1fd7452a9b875a8be7b93335f41abda (patch)
tree43abe79c1b540741f0a0d0a62b6c3a0e5d515f4e /enum.c
parent2735da2039b9e441e41b11b606ba362db350a658 (diff)
Respect visibility in non-array Enumerable#inject [Bug #13592]
Diffstat (limited to 'enum.c')
-rw-r--r--enum.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/enum.c b/enum.c
index 8769680..69c1641 100644
--- a/enum.c
+++ b/enum.c
@@ -734,7 +734,7 @@ inject_op_i(RB_BLOCK_CALL_FUNC_ARGLIST(i, p))
}
else if (SYMBOL_P(name = memo->u3.value)) {
const ID mid = SYM2ID(name);
- MEMO_V1_SET(memo, rb_funcallv(memo->v1, mid, 1, &i));
+ MEMO_V1_SET(memo, rb_funcallv_public(memo->v1, mid, 1, &i));
}
else {
VALUE args[2];