String#{lines,chars,codepoints,bytes} now return an array.
string.c (rb_str_each_line, rb_str_lines): String#lines now
returns an array instead of an enumerator. Passing a block is
deprecated but still supported for backwards compatibility.
Based on the patch by yhara. [Feature #6670]
string.c (rb_str_each_char, rb_str_chars): Ditto for
String#chars.
string.c (rb_str_each_codepoint, rb_str_codepoints): Ditto for
String#codepoints.
string.c (rb_str_each_byte, rb_str_bytes): Ditto for
String#bytes.
String#{lines,chars,codepoints,bytes} now return an array.
string.c (rb_str_each_line, rb_str_lines): String#lines now
returns an array instead of an enumerator. Passing a block is
deprecated but still supported for backwards compatibility.
Based on the patch by yhara. [Feature #6670]
string.c (rb_str_each_char, rb_str_chars): Ditto for
String#chars.
string.c (rb_str_each_codepoint, rb_str_codepoints): Ditto for
String#codepoints.
string.c (rb_str_each_byte, rb_str_bytes): Ditto for
String#bytes.
NEWS: Add notes for the above changes.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@37838 b2dd03c8-39d4-4d8f-98ff-823fe69b080e