General

Profile

nickkelley (Nick Kelley)

  • Login: nickkelley
  • Registered on: 04/30/2021
  • Last sign in: 12/07/2021

Issues

open closed Total
Assigned issues 0 1 1
Reported issues 0 1 1

Activity

04/30/2021

10:46 PM Ruby Misc #17842 (Closed): Example incorrect in documentation for Hash#dig
Applied in changeset commit:git|a9824a3113ee5342e7ac90387de9f3b9d5ec9e0a.
----------
Correct documentation example on Hash#dig
Fixes [Misc #17842]. The current documentation suggests that:
{foo: {bar: {baz: 2}}}.dig(:foo, :bar...
nickkelley (Nick Kelley)
10:37 PM Ruby Misc #17842: Example incorrect in documentation for Hash#dig
Here is a pull request that fixes the comment: https://github.com/ruby/ruby/pull/4441
nickkelley (Nick Kelley)
10:30 PM Ruby Misc #17842 (Closed): Example incorrect in documentation for Hash#dig
In the current examples for Hash#dig, we have:
```
h = {foo: {bar: {baz: 2}}}
h.dig(:foo) # => {:bar=>{:baz=>2}}
h.dig(:foo, :bar) # => {:bar=>{:baz=>2}} <-- incorrect return value
```
This should be:
```
h = {foo: {bar: {baz: ...
nickkelley (Nick Kelley)
10:46 PM Ruby Revision a9824a31 (git): Correct documentation example on Hash#dig
Fixes [Misc #17842]. The current documentation suggests that:
{foo: {bar: {baz: 2}}}.dig(:foo, :bar) # => {:bar=>{:baz=>2}}
when it should be:
{foo: {bar: {baz: 2}}}.dig(:foo, :bar) # => {:baz=>2}
nickkelley (Nick Kelley)

Also available in: Atom