зеркало из https://github.com/github/ruby.git
[ruby/irb] Use class methods of `File` over `Kernel.open`
https://github.com/ruby/irb/commit/e0ec5e1bd8
This commit is contained in:
Родитель
cf3b305c43
Коммит
d532d27507
|
@ -70,7 +70,7 @@ module IRB
|
|||
end
|
||||
history_file = IRB.rc_file("_history") unless history_file
|
||||
if File.exist?(history_file)
|
||||
open(history_file, "r:#{IRB.conf[:LC_MESSAGES].encoding}") do |f|
|
||||
File.open(history_file, "r:#{IRB.conf[:LC_MESSAGES].encoding}") do |f|
|
||||
f.each { |l|
|
||||
l = l.chomp
|
||||
if self.class == RelineInputMethod and history.last&.end_with?("\\")
|
||||
|
|
Загрузка…
Ссылка в новой задаче