[前][次][番号順一覧][スレッド一覧]

ruby-changes:42696

From: usa <ko1@a...>
Date: Tue, 26 Apr 2016 12:24:55 +0900 (JST)
Subject: [ruby-changes:42696] usa:r54770 (ruby_2_2): merge revision(s) 54720: [Backport #12184]

usa	2016-04-26 13:21:14 +0900 (Tue, 26 Apr 2016)

  New Revision: 54770

  https://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=54770

  Log:
    merge revision(s) 54720: [Backport #12184]
    
    * ruby.c: cygwin does not use w32_cmdvector, command line can be
      other than UTF-8.  [ruby-dev:49519] [Bug #12184]

  Modified directories:
    branches/ruby_2_2/
  Modified files:
    branches/ruby_2_2/ChangeLog
    branches/ruby_2_2/ruby.c
    branches/ruby_2_2/test/ruby/test_rubyoptions.rb
    branches/ruby_2_2/version.h
Index: ruby_2_2/ruby.c
===================================================================
--- ruby_2_2/ruby.c	(revision 54769)
+++ ruby_2_2/ruby.c	(revision 54770)
@@ -338,7 +338,9 @@ translit_char_bin(char *p, int from, int https://github.com/ruby/ruby/blob/trunk/ruby_2_2/ruby.c#L338
 	p++;
     }
 }
+#endif
 
+#ifdef _WIN32
 # define UTF8_PATH 1
 #endif
 
Index: ruby_2_2/ChangeLog
===================================================================
--- ruby_2_2/ChangeLog	(revision 54769)
+++ ruby_2_2/ChangeLog	(revision 54770)
@@ -1,3 +1,8 @@ https://github.com/ruby/ruby/blob/trunk/ruby_2_2/ChangeLog#L1
+Tue Apr 26 13:18:59 2016  Nobuyoshi Nakada  <nobu@r...>
+
+	* ruby.c: cygwin does not use w32_cmdvector, command line can be
+	  other than UTF-8.  [ruby-dev:49519] [Bug #12184]
+
 Tue Apr 26 13:16:41 2016  Nobuyoshi Nakada  <nobu@r...>
 
 	* eval_jump.c (exec_end_procs_chain): restore previous error info
Index: ruby_2_2/version.h
===================================================================
--- ruby_2_2/version.h	(revision 54769)
+++ ruby_2_2/version.h	(revision 54770)
@@ -1,6 +1,6 @@ https://github.com/ruby/ruby/blob/trunk/ruby_2_2/version.h#L1
 #define RUBY_VERSION "2.2.5"
 #define RUBY_RELEASE_DATE "2016-04-26"
-#define RUBY_PATCHLEVEL 315
+#define RUBY_PATCHLEVEL 316
 
 #define RUBY_RELEASE_YEAR 2016
 #define RUBY_RELEASE_MONTH 4
Index: ruby_2_2/test/ruby/test_rubyoptions.rb
===================================================================
--- ruby_2_2/test/ruby/test_rubyoptions.rb	(revision 54769)
+++ ruby_2_2/test/ruby/test_rubyoptions.rb	(revision 54770)
@@ -698,7 +698,8 @@ class TestRubyOptions < Test::Unit::Test https://github.com/ruby/ruby/blob/trunk/ruby_2_2/test/ruby/test_rubyoptions.rb#L698
     end
   end
 
-  if /mswin|mingw/ =~ RUBY_PLATFORM
+  case RUBY_PLATFORM
+  when /mswin|mingw/
     def test_command_line_glob_nonascii
       bug10555 = '[ruby-dev:48752] [Bug #10555]'
       name = "\u{3042}.txt"
@@ -728,9 +729,7 @@ class TestRubyOptions < Test::Unit::Test https://github.com/ruby/ruby/blob/trunk/ruby_2_2/test/ruby/test_rubyoptions.rb#L729
         assert_in_out_err(["-e", "", "test/*"], "", [], [], bug10941)
       end
     end
-  end
 
-  if /mswin|mingw/ =~ RUBY_PLATFORM
     Ougai = %W[\u{68ee}O\u{5916}.txt \u{68ee 9d0e 5916}.txt \u{68ee 9dd7 5916}.txt]
     def test_command_line_glob_noncodepage
       with_tmpchdir do |dir|
@@ -740,6 +739,14 @@ class TestRubyOptions < Test::Unit::Test https://github.com/ruby/ruby/blob/trunk/ruby_2_2/test/ruby/test_rubyoptions.rb#L739
         assert_in_out_err(["-e", "puts ARGV", "*.txt"], "", ougai)
       end
     end
+  when /cygwin/
+    def test_command_line_non_ascii
+      assert_separately([{"LC_ALL"=>"ja_JP.SJIS"}, "-", "\u{3042}".encode("SJIS")], <<-"end;")
+        bug12184 = '[ruby-dev:49519] [Bug #12184]'
+        a = ARGV[0]
+        assert_equal([Encoding::SJIS, 130, 160], [a.encoding, *a.bytes], bug12184)
+      end;
+    end
   end
 
   def test_script_is_directory

Property changes on: ruby_2_2
___________________________________________________________________
Modified: svn:mergeinfo
   Merged /trunk:r54720


--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]