Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix slice_before on empty enumerable #822

Merged
merged 1 commit into from Jun 24, 2013

Conversation

Projects
None yet
2 participants
@statianzo
Copy link
Contributor

statianzo commented Jun 24, 2013

This fixes an issue where calling slice_before on an empty enumerable
would return an enumerable containing one element of nil

#before
[].slice_before(1).to_a #=> [nil]
#after
[].slice_before(1).to_a #=> []

Would you also like a test added to rubyspec around this?

fix slice_before on empty enumerable
This fixes an issue where calling slice_before on an empty enumerable
would return an enumerable containing one element of nil

BanzaiMan added a commit that referenced this pull request Jun 24, 2013

Merge pull request #822 from statianzo/slice_before-fix
fix slice_before on empty enumerable

@BanzaiMan BanzaiMan merged commit 69744e1 into jruby:master Jun 24, 2013

1 check passed

default The Travis CI build passed
Details
@BanzaiMan

This comment has been minimized.

Copy link
Member

BanzaiMan commented Jun 24, 2013

Thanks! The test should go to RubySpec.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.