[DOC] Tweaks for Array#drop
This commit is contained in:
parent
309362d6c5
commit
0906b16277
Notes:
git
2024-09-11 12:49:08 +00:00
6
array.c
6
array.c
@ -7697,9 +7697,9 @@ rb_ary_take_while(VALUE ary)
|
|||||||
|
|
||||||
/*
|
/*
|
||||||
* call-seq:
|
* call-seq:
|
||||||
* array.drop(n) -> new_array
|
* drop(n) -> new_array
|
||||||
*
|
*
|
||||||
* Returns a new +Array+ containing all but the first +n+ element of +self+,
|
* Returns a new array containing all but the first +n+ element of +self+,
|
||||||
* where +n+ is a non-negative Integer;
|
* where +n+ is a non-negative Integer;
|
||||||
* does not modify +self+.
|
* does not modify +self+.
|
||||||
*
|
*
|
||||||
@ -7709,7 +7709,9 @@ rb_ary_take_while(VALUE ary)
|
|||||||
* a.drop(0) # => [0, 1, 2, 3, 4, 5]
|
* a.drop(0) # => [0, 1, 2, 3, 4, 5]
|
||||||
* a.drop(1) # => [1, 2, 3, 4, 5]
|
* a.drop(1) # => [1, 2, 3, 4, 5]
|
||||||
* a.drop(2) # => [2, 3, 4, 5]
|
* a.drop(2) # => [2, 3, 4, 5]
|
||||||
|
* a.drop(9) # => []
|
||||||
*
|
*
|
||||||
|
* Related: see {Methods for Fetching}[rdoc-ref:Array@Methods+for+Fetching].
|
||||||
*/
|
*/
|
||||||
|
|
||||||
static VALUE
|
static VALUE
|
||||||
|
Loading…
x
Reference in New Issue
Block a user