Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: jruby/jruby
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: 579c8ffb469d
Choose a base ref
...
head repository: jruby/jruby
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: b1880ea37106
Choose a head ref
  • 2 commits
  • 2 files changed
  • 2 contributors

Commits on Mar 14, 2015

  1. Copy the full SHA
    1b43c83 View commit details
  2. Merge pull request #2701 from bjfish/truffle_array_delete_at_nil

    [Truffle] Returning nil for out of range Array#delete_at
    chrisseaton committed Mar 14, 2015
    Copy the full SHA
    b1880ea View commit details
Showing with 2 additions and 4 deletions.
  1. +0 −1 spec/truffle/tags/core/array/delete_at_tags.txt
  2. +2 −3 truffle/src/main/java/org/jruby/truffle/nodes/core/ArrayNodes.java
1 change: 0 additions & 1 deletion spec/truffle/tags/core/array/delete_at_tags.txt

This file was deleted.

Original file line number Diff line number Diff line change
@@ -806,11 +806,10 @@ public Object deleteAtIntegerFixnum(RubyArray array, int index) {

if (normalizedIndex < 0) {
tooSmallBranch.enter();
CompilerDirectives.transferToInterpreter();
throw new UnsupportedOperationException();
return getContext().getCoreLibrary().getNilObject();
} else if (normalizedIndex >= array.getSize()) {
beyondEndBranch.enter();
throw new UnsupportedOperationException();
return getContext().getCoreLibrary().getNilObject();
} else {
final int[] store = (int[]) array.getStore();
final int value = store[normalizedIndex];