Feature #1667

IO#codepoints, IO#each_codepoint, and StringIO

Added by Marc-Andre Lafortune over 2 years ago. Updated 10 months ago.

[ruby-core:23949]
Status:Closed Start date:06/20/2009
Priority:Normal Due date:
Assignee:- % Done:

100%

Category:core
Target version:1.9.2

Description

Almost all "iterators" of String are present in IO and StringIO: #each_char, #each_byte, #each_line and their corresponding #chars, #bytes, #lines. Only #each_codepoint and #codepoints are not defined in IO and StringIO.

Unless there is a compelling reason not to, it would be useful if these were defined. This would mirror the coherence with all other each_* methods that exist in both String, IO and StringIO.

Associated revisions

Revision 23818
Added by Yukihiro Matsumoto over 2 years ago

* ext/stringio/stringio.c (strio_each_codepoint): new method. [ruby-core:23949] * ext/stringio/stringio.c (strio_each_codepoint): ditto.

History

Updated by Yukihiro Matsumoto over 2 years ago

  • Status changed from Open to Closed
  • % Done changed from 0 to 100
Applied in changeset r23818.

Also available in: Atom PDF