Skip to content

Commit

Permalink
Always recheck length as in combination.
Browse files Browse the repository at this point in the history
headius committed Oct 18, 2017
1 parent 4f956b9 commit ee9d51c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion core/src/main/java/org/jruby/RubyArray.java
Original file line number Diff line number Diff line change
@@ -3831,7 +3831,7 @@ public IRubyObject repeatedCombination(ThreadContext context, IRubyObject num, B
} else if (n == 0) {
block.yield(context, newEmptyArray(runtime));
} else if (n == 1) {
for (int i = 0; i < len; i++) {
for (int i = 0; i < realLength; i++) {
block.yield(context, newArray(runtime, eltOk(i)));
}
} else {

0 comments on commit ee9d51c

Please sign in to comment.