mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
Use IRB::InputMethod#eof? to quit
This commit is contained in:
parent
1d301acbe8
commit
9840f52c77
2 changed files with 2 additions and 2 deletions
|
@ -260,7 +260,7 @@ module IRB
|
|||
#
|
||||
# See IO#eof? for more information.
|
||||
def eof?
|
||||
@eof
|
||||
super
|
||||
end
|
||||
|
||||
# Whether this input method is still readable when there is no more data to
|
||||
|
|
|
@ -98,7 +98,7 @@ class RubyLex
|
|||
@line.force_encoding(@io.encoding)
|
||||
yield @line, @exp_line_no
|
||||
end
|
||||
break unless l
|
||||
break if @io.eof?
|
||||
@line = ''
|
||||
@exp_line_no = @line_no
|
||||
|
||||
|
|
Loading…
Reference in a new issue