mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* array.c (rb_ary_pop): rdoc update for new usage. [ruby-core:03022]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@6468 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
7a28fb146f
commit
1135c41a5b
1 changed files with 4 additions and 3 deletions
7
array.c
7
array.c
|
@ -576,9 +576,10 @@ rb_ary_pop(ary)
|
||||||
* Removes the last element from <i>self</i> and returns it, or
|
* Removes the last element from <i>self</i> and returns it, or
|
||||||
* <code>nil</code> if the array is empty.
|
* <code>nil</code> if the array is empty.
|
||||||
*
|
*
|
||||||
* a = [ "a", "m", "z" ]
|
* a = [ "a", "b", "c", "d" ]
|
||||||
* a.pop #=> "z"
|
* a.pop #=> "d"
|
||||||
* a #=> ["a", "m"]
|
* a.pop(2) #=> ["b", "c"]
|
||||||
|
* a #=> ["a"]
|
||||||
*/
|
*/
|
||||||
|
|
||||||
static VALUE
|
static VALUE
|
||||||
|
|
Loading…
Reference in a new issue