summaryrefslogtreecommitdiffstats
path: root/array.c
diff options
context:
space:
mode:
authormatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2004-07-24 09:48:21 +0000
committermatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2004-07-24 09:48:21 +0000
commit8006f6f71f8c3370a702a21f3ea65d7300ae5bf7 (patch)
treeb5a3121173a5179382f052482ee4b92e7b9349f1 /array.c
parentfa0053812ac44024ea9a6cedeb70b5535868d191 (diff)
downloadruby-8006f6f71f8c3370a702a21f3ea65d7300ae5bf7.tar.gz
ruby-8006f6f71f8c3370a702a21f3ea65d7300ae5bf7.tar.xz
ruby-8006f6f71f8c3370a702a21f3ea65d7300ae5bf7.zip
* range.c (rb_range_beg_len): returns Qnil only when "beg" points
outside of a range. No boundary check for "end". git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@6692 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'array.c')
-rw-r--r--array.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/array.c b/array.c
index 4575d815a..b90eb995a 100644
--- a/array.c
+++ b/array.c
@@ -774,10 +774,8 @@ rb_ary_subseq(ary, beg, len)
* continuing for _length_ elements, or returns a subarray
* specified by _range_.
* Negative indices count backward from the end of the
- * array (-1 is the last element). Returns nil if any indices
- * are out of range unless the index equals the array size and a
- * _length_ or _range_ parameter is given, in which case an
- * empty array is returned.
+ * array (-1 is the last element). Returns nil if the index
+ * (or starting index) are out of range.
*
* a = [ "a", "b", "c", "d", "e" ]
* a[2] + a[0] + a[1] #=> "cab"