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: cdb0351278f0
Choose a base ref
...
head repository: jruby/jruby
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: 30783af23dad
Choose a head ref
  • 2 commits
  • 1 file changed
  • 2 contributors

Commits on Jul 31, 2017

  1. Fix error message in Hash#fetch

    In Hash#fetch, the old error message assumed the key was a symbol. Instead we
    inspect it like in MRI. This closes #4729.
    rawrafox committed Jul 31, 2017
    Copy the full SHA
    0214fcd View commit details

Commits on Aug 7, 2017

  1. Merge pull request #4730 from rawrasaur/fix-hash-fetch-error-message

    Fix error message in Hash#fetch
    headius authored Aug 7, 2017
    Copy the full SHA
    30783af View commit details
Showing with 1 addition and 1 deletion.
  1. +1 −1 core/src/main/java/org/jruby/RubyHash.java
2 changes: 1 addition & 1 deletion core/src/main/java/org/jruby/RubyHash.java
Original file line number Diff line number Diff line change
@@ -1192,7 +1192,7 @@ public IRubyObject fetch(ThreadContext context, IRubyObject key, Block block) {
if (value == null) {
if (block.isGiven()) return block.yield(context, key);

throw runtime.newKeyError("key not found: :" + key);
throw runtime.newKeyError("key not found: " + key.inspect());
}

return value;