1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

* array.c (rb_get_values_at): Improve rdoc

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@37770 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
marcandre 2012-11-20 15:03:52 +00:00
parent 68de2e5800
commit aa58a684b7

View file

@ -2607,10 +2607,10 @@ rb_get_values_at(VALUE obj, long olen, int argc, VALUE *argv, VALUE (*func) (VAL
* See also Array#select.
*
* a = %w{ a b c d e f }
* a.values_at(1, 3, 5)
* a.values_at(1, 3, 5, 7)
* a.values_at(-1, -3, -5, -7)
* a.values_at(1..3, 2...5)
* a.values_at(1, 3, 5) # => ["b", "d", "f"]
* a.values_at(1, 3, 5, 7) # => ["b", "d", "f", nil]
* a.values_at(-1, -2, -2, -7) # => ["f", "e", "e", nil]
* a.values_at(4..6, 3...6) # => ["e", "f", nil, "d", "e", "f"]
*/
static VALUE