[ruby-core:116684] [Ruby master Feature#20261] Add symbol alternatives to '' and nil for IO line separators

Issue #20261 has been reported by burdettelamar (Burdette Lamar). ---------------------------------------- Feature #20261: Add symbol alternatives to '' and nil for IO line separators https://bugs.ruby-lang.org/issues/20261 * Author: burdettelamar (Burdette Lamar) * Status: Open * Priority: Normal ---------------------------------------- For IO's line-oriented read methods, there are two special values for the line-separator argument `sep`; I'm proposing to add (user-friendlier) symbol synonyms for those values: - `:paragraph` as synonym for `''` (read paragraphs). - `:slurp` as synonym for `nil` (read all). Details (code, documentation, tests) may be seen at https://github.com/ruby/ruby/pull/9921. -- https://bugs.ruby-lang.org/

Issue #20261 has been updated by burdettelamar (Burdette Lamar). Assignee set to burdettelamar (Burdette Lamar) Propose to add user-friendly synonyms (symbols) for IO line separator arguments `''` (read paragraphs) and `nil` (read all). New symbol arguments would be `:paragraph` and `:slurp`. (I think this use of the term _slurp_ is common in Perl and Python.) ---------------------------------------- Feature #20261: Add symbol synonyms for '' and nil for IO method line separator arguments https://bugs.ruby-lang.org/issues/20261#change-106880 * Author: burdettelamar (Burdette Lamar) * Status: Open * Priority: Normal * Assignee: burdettelamar (Burdette Lamar) ---------------------------------------- For IO's line-oriented read methods, there are two special values for the line-separator argument `sep`; I'm proposing to add (user-friendlier) symbol synonyms for those values: - `:paragraph` as synonym for `''` (read paragraphs). - `:slurp` as synonym for `nil` (read all). Details (code, documentation, tests) may be seen at https://github.com/ruby/ruby/pull/9921. -- https://bugs.ruby-lang.org/

Issue #20261 has been updated by mame (Yusuke Endoh). Discussed at the dev meeting, and @matz (Yukihiro Matsumoto) said he wants to take time to consider it. No conclusion is reached. ---------------------------------------- Feature #20261: Add symbol synonyms for '' and nil for IO method line separator arguments https://bugs.ruby-lang.org/issues/20261#change-107241 * Author: burdettelamar (Burdette Lamar) * Status: Open * Assignee: burdettelamar (Burdette Lamar) ---------------------------------------- [Feature 20261] For IO's line-oriented read methods, there are two special values for the line-separator argument `sep`; I'm proposing to add (user-friendlier) symbol synonyms for those values: - `:paragraph` as synonym for `''` (read paragraphs). - `:slurp` as synonym for `nil` (read all). Details (code, documentation, tests) may be seen at https://github.com/ruby/ruby/pull/9921. -- https://bugs.ruby-lang.org/
participants (2)
-
burdettelamar (Burdette Lamar)
-
mame (Yusuke Endoh)