ruby-changes:47209
From: kazu <ko1@a...>
Date: Fri, 14 Jul 2017 08:55:56 +0900 (JST)
Subject: [ruby-changes:47209] kazu:r59324 (trunk): Use tr! instead of gsub!
kazu 2017-07-14 08:55:41 +0900 (Fri, 14 Jul 2017) New Revision: 59324 https://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=59324 Log: Use tr! instead of gsub! Modified files: trunk/test/ruby/test_rubyoptions.rb Index: test/ruby/test_rubyoptions.rb =================================================================== --- test/ruby/test_rubyoptions.rb (revision 59323) +++ test/ruby/test_rubyoptions.rb (revision 59324) @@ -453,7 +453,7 @@ class TestRubyOptions < Test::Unit::Test https://github.com/ruby/ruby/blob/trunk/test/ruby/test_rubyoptions.rb#L453 notexist = "./notexist.rb" dir, *rubybin = RbConfig::CONFIG.values_at('bindir', 'RUBY_INSTALL_NAME', 'EXEEXT') rubybin = "#{dir}/#{rubybin.join('')}" - rubybin.gsub!(%r(/), '\\') if /mswin|mingw/ =~ RUBY_PLATFORM + rubybin.tr!('/', '\\') if /mswin|mingw/ =~ RUBY_PLATFORM rubybin = Regexp.quote(rubybin) pat = Regexp.quote(notexist) bug1573 = '[ruby-core:23717]' -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/