mirror of
https://github.com/mruby/mruby
synced 2026-06-08 16:11:16 +00:00
Merge pull request #3232 from lukaselmer/patch-1
Update documentation of fetch
This commit is contained in:
@@ -275,8 +275,9 @@ class Array
|
||||
# +default+ value.
|
||||
#
|
||||
# Alternatively, if a block is given it will only be executed when an
|
||||
# invalid +index+ is referenced. Negative values of +index+ count from the
|
||||
# end of the array.
|
||||
# invalid +index+ is referenced.
|
||||
#
|
||||
# Negative values of +index+ count from the end of the array.
|
||||
#
|
||||
# a = [ 11, 22, 33, 44 ]
|
||||
# a.fetch(1) #=> 22
|
||||
|
||||
Reference in New Issue
Block a user