ruby-changes:62628
From: Nobuyoshi <ko1@a...>
Date: Tue, 18 Aug 2020 19:16:13 +0900 (JST)
Subject: [ruby-changes:62628] f2435c1508 (master): [ruby/reline] Get rid of loading pathname unnecessarily
https://git.ruby-lang.org/ruby.git/commit/?id=f2435c1508 From f2435c15089f5789a1ad6bd5bd57d4ae5a9913c2 Mon Sep 17 00:00:00 2001 From: Nobuyoshi Nakada <nobu@r...> Date: Wed, 12 Aug 2020 11:09:25 +0900 Subject: [ruby/reline] Get rid of loading pathname unnecessarily https://github.com/ruby/reline/commit/9bd54b7f1c diff --git a/lib/reline/config.rb b/lib/reline/config.rb index 1cd6079..370d100 100644 --- a/lib/reline/config.rb +++ b/lib/reline/config.rb @@ -1,5 +1,3 @@ https://github.com/ruby/ruby/blob/trunk/lib/reline/config.rb#L1 -require 'pathname' - class Reline::Config attr_reader :test_mode diff --git a/lib/reline/line_editor.rb b/lib/reline/line_editor.rb index 4eee4bd..c9d88ed 100644 --- a/lib/reline/line_editor.rb +++ b/lib/reline/line_editor.rb @@ -2,7 +2,6 @@ require 'reline/kill_ring' https://github.com/ruby/ruby/blob/trunk/lib/reline/line_editor.rb#L2 require 'reline/unicode' require 'tempfile' -require 'pathname' class Reline::LineEditor # TODO: undo @@ -2145,7 +2144,7 @@ class Reline::LineEditor https://github.com/ruby/ruby/blob/trunk/lib/reline/line_editor.rb#L2144 fp.path } system("#{ENV['EDITOR']} #{path}") - @line = Pathname.new(path).read + @line = File.read(path) finish end -- cgit v0.10.2 -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/