diff options
-rw-r--r-- | ChangeLog | 5 | ||||
-rw-r--r-- | array.c | 5 | ||||
-rw-r--r-- | object.c | 5 |
3 files changed, 13 insertions, 2 deletions
@@ -1,3 +1,8 @@ +Tue Feb 19 12:30:00 2013 Zachary Scott <zachary@zacharyscott.net> + + * object.c: rdoc formatting for Kernel#Array() + * array.c: Add rdoc for Array() method to Creating Arrays section + Tue Feb 19 10:35:52 2013 Eric Hodel <drbrain@segment7.net> * ext/openssl/ossl.c (class OpenSSL): Use only inner parenthesis in @@ -5240,6 +5240,11 @@ rb_ary_drop_while(VALUE ary) * empty_table = Array.new(3) { Array.new(3) } * #=> [[nil, nil, nil], [nil, nil, nil], [nil, nil, nil]] * + * An array can also be created by using the Array() method, provided by + * Kernel, which calls #to_ary or #to_a on it's argument. + * + * Array({:a => "a", :b => "b"}) #=> [[:a, "a"], [:b, "b"]] + * * == Example Usage * * In addition to the methods it mixes in through the Enumerable module, the @@ -2727,8 +2727,9 @@ rb_Array(VALUE val) * call-seq: * Array(arg) -> array * - * Returns <i>arg</i> as an <code>Array</code>. First tries to call - * <i>arg</i><code>.to_ary</code>, then <i>arg</i><code>.to_a</code>. + * Returns +arg+ as an Array. + * + * First tries to call Array#to_ary on +arg+, then Array#to_a. * * Array(1..5) #=> [1, 2, 3, 4, 5] */ |