[前][次][番号順一覧][スレッド一覧]

ruby-changes:3732

From: ko1@a...
Date: Thu, 24 Jan 2008 23:25:24 +0900 (JST)
Subject: [ruby-changes:3732] mame - Ruby:r15221 (trunk): * enum.c (enum_one, enum_take_while, enum_drop_while): fix documents.

mame	2008-01-24 23:23:51 +0900 (Thu, 24 Jan 2008)

  New Revision: 15221

  Modified files:
    trunk/ChangeLog
    trunk/enum.c

  Log:
    * enum.c (enum_one, enum_take_while, enum_drop_while): fix documents.


  http://svn.ruby-lang.org/cgi-bin/viewvc.cgi/trunk/ChangeLog?r1=15221&r2=15220&diff_format=u
  http://svn.ruby-lang.org/cgi-bin/viewvc.cgi/trunk/enum.c?r1=15221&r2=15220&diff_format=u

Index: ChangeLog
===================================================================
--- ChangeLog	(revision 15220)
+++ ChangeLog	(revision 15221)
@@ -1,3 +1,7 @@
+Thu Jan 24 23:23:06 2008  Yusuke Endoh  <mame@t...>
+
+	* enum.c (enum_one, enum_take_while, enum_drop_while): fix documents.
+
 Thu Jan 24 21:46:24 2008  Tanaka Akira  <akr@f...>
 
 	* parse.y (reg_fragment_setenc_gen): associate ASCII-8BIT only if
@@ -97,7 +101,7 @@
 
 Thu Jan 24 02:13:07 2008  Yusuke Endoh  <mame@t...>
 
-	* insns.def (expandarray): fix stack inc.
+	* insns.def (expandarray): fix stack inc.  [ruby-dev:32892]
 	* bootstraptest/test_knownbug.rb, test_massign.rb: move a fixed test.
 
 Thu Jan 24 01:00:34 2008  NARUSE, Yui  <naruse@r...>
Index: enum.c
===================================================================
--- enum.c	(revision 15220)
+++ enum.c	(revision 15221)
@@ -863,7 +863,8 @@
  *  true.
  *     
  *     %w{ant bear cat}.one? {|word| word.length == 4}   #=> true
- *     %w{ant bear cat}.one? {|word| word.length >= 4}   #=> false
+ *     %w{ant bear cat}.one? {|word| word.length > 4}    #=> false
+ *     %w{ant bear cat}.one? {|word| word.length < 4}    #=> false
  *     [ nil, true, 99 ].one?                            #=> false
  *     [ nil, true, false ].one?                         #=> true
  *     
@@ -1223,7 +1224,7 @@
     rb_block_call(obj, id_each, 0, 0, max_by_i, (VALUE)memo);
     return memo[1];
 }
-
+ 
 static VALUE
 minmax_by_i(VALUE i, VALUE *memo, int argc, VALUE *argv)
 {
@@ -1484,7 +1485,7 @@
  *  then stops iterating and returns an array of all prior elements.
  *     
  *     a = [1, 2, 3, 4, 5, 0]
- *     a.take {|i| i < 3 }   # => [1, 2]
+ *     a.take_while {|i| i < 3 }   # => [1, 2]
  *     
  */
 
@@ -1556,7 +1557,7 @@
  *  containing the remaining elements.
  *     
  *     a = [1, 2, 3, 4, 5, 0]
- *     a.drop {|i| i < 3 }   # => [3, 4, 5, 0]
+ *     a.drop_while {|i| i < 3 }   # => [3, 4, 5, 0]
  *     
  */
 

--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]