From 1e22306569e43251f946145ab49662ee6fe76151 Mon Sep 17 00:00:00 2001 From: naruse Date: Tue, 12 Oct 2010 09:25:33 +0000 Subject: * string.c (rb_str_concat): use unsigned int for GB18030. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29453 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- test/ruby/test_m17n_comb.rb | 3 +++ 1 file changed, 3 insertions(+) (limited to 'test/ruby') diff --git a/test/ruby/test_m17n_comb.rb b/test/ruby/test_m17n_comb.rb index cf80377172..e730f6f0e8 100644 --- a/test/ruby/test_m17n_comb.rb +++ b/test/ruby/test_m17n_comb.rb @@ -346,6 +346,9 @@ class TestM17NComb < Test::Unit::TestCase assert_raise(Encoding::CompatibilityError) { s << s2 } end } + + assert_equal("A\x84\x31\xA4\x39".force_encoding("GB18030"), + "A".force_encoding("GB18030") << 0x8431A439) end def test_str_aref -- cgit v1.2.3