Skip to content

Commit f6bb8d8

Browse files
ParadoxV5soutaro
authored andcommitted
IO#each_line and Kernel#readlines accept chomp: true
1 parent 393e2dd commit f6bb8d8

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

core/io.rbs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3104,8 +3104,8 @@ class IO < Object
31043104
#
31053105
# Returns an Enumerator if no block is given.
31063106
#
3107-
def each_line: (?String sep, ?Integer limit) { (String line) -> void } -> self
3108-
| (?String sep, ?Integer limit) -> ::Enumerator[String, self]
3107+
def each_line: (?string sep, ?int limit, ?chomp: boolish) { (String line) -> void } -> self
3108+
| (?string sep, ?int limit, ?chomp: boolish) -> ::Enumerator[String, self]
31093109

31103110
# <!--
31113111
# rdoc-file=io.c

core/kernel.rbs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1499,7 +1499,7 @@ module Kernel : BasicObject
14991499
# Optional keyword arguments `enc_opts` specify encoding options; see [Encoding
15001500
# options](rdoc-ref:encodings.rdoc@Encoding+Options).
15011501
#
1502-
def self?.readlines: (?String arg0, ?Integer arg1) -> ::Array[String]
1502+
def self?.readlines: (?string sep, ?int limit, ?chomp: boolish) -> ::Array[String]
15031503

15041504
# <!--
15051505
# rdoc-file=lib/rubygems/core_ext/kernel_require.rb

0 commit comments

Comments
 (0)