From 1135c41a5bfece4b4db3bba472c30d31c5891fe1 Mon Sep 17 00:00:00 2001 From: nobu Date: Wed, 16 Jun 2004 12:52:59 +0000 Subject: [PATCH] * 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 --- array.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/array.c b/array.c index 78eb15054e..ccdcc3d506 100644 --- a/array.c +++ b/array.c @@ -576,9 +576,10 @@ rb_ary_pop(ary) * Removes the last element from self and returns it, or * nil if the array is empty. * - * a = [ "a", "m", "z" ] - * a.pop #=> "z" - * a #=> ["a", "m"] + * a = [ "a", "b", "c", "d" ] + * a.pop #=> "d" + * a.pop(2) #=> ["b", "c"] + * a #=> ["a"] */ static VALUE