Skip to content

Commit

Permalink
Fix documentation of Hash#put_if_absent (crystal-lang#13898)
Browse files Browse the repository at this point in the history
  • Loading branch information
ilmanzo authored Oct 26, 2023
1 parent 008d76a commit ad7d42c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/hash.cr
Original file line number Diff line number Diff line change
Expand Up @@ -1075,7 +1075,7 @@ class Hash(K, V)
# Otherwise *value* is returned.
#
# ```
# h = {} of Int32 => Array(String)
# h = {} of Int32 => String
# h.put_if_absent(1, "one") # => "one"
# h.put_if_absent(1, "uno") # => "one"
# h.put_if_absent(2, "two") # => "two"
Expand Down

0 comments on commit ad7d42c

Please sign in to comment.