diff options
author | marcandre <marcandre@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2018-12-12 19:51:50 +0000 |
---|---|---|
committer | marcandre <marcandre@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2018-12-12 19:51:50 +0000 |
commit | fc4029b8434851fa82f8f3443789e10b9b20411b (patch) | |
tree | 69dc526634253c3f1540dc8fbad6c5e0ccb71a97 | |
parent | 296bd00e02573a231ec52da538fc3b7d9745f688 (diff) |
NEWS: Mention (1...) in addition to (1..) [DOC]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@66370 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r-- | NEWS | 5 |
1 files changed, 3 insertions, 2 deletions
@@ -27,10 +27,11 @@ sufficient information, see the ChangeLog file or Redmine * constant names may start with a non-ASCII capital letter. [Feature #13770] * An endless range is introduced. You can write a range that has no end, - like <code>(0..)</code>. The following shows typical use cases. [Feature #12912] + like <code>(0..)</code> (or similarly <code>(0...)</code>). + The following shows typical use cases. [Feature #12912] ary[1..] # identical to ary[1..-1] - (1..).each {|index| ... } # infinite loop from index 1 + (1...).each {|index| ... } # infinite loop from index 1 ary.zip(1..) {|elem, index| ... } # ary.each.with_index(1) { } * Non-Symbol key in keyword arguments hash causes an exception. |