From 33b5b4da890ca17ef45f94edaf5610363e57ad2c Mon Sep 17 00:00:00 2001 From: yugui Date: Sun, 25 Oct 2009 14:46:28 +0000 Subject: merges r24513,r24514 and r24515 from trunk into ruby_1_9_1. -- * class.c (rb_define_class_id_under, rb_define_module_id_under): new functions to define a nested class/module with non-ascii name. * struct.c (make_struct): use name with encoding. * struct.c (inspect_struct): ditto. [ruby-core:24849] -- * test/ruby/test_marshal.rb (test_class_nonascii): test for non-ascii name class. -- * class.c (rb_define_module_id_under): fix the name. * class.c (rb_define_module_under): fix for prevvious changes. git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_9_1@25479 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- test/ruby/test_marshal.rb | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'test/ruby/test_marshal.rb') diff --git a/test/ruby/test_marshal.rb b/test/ruby/test_marshal.rb index 4a9192d44..172bfbb3f 100644 --- a/test/ruby/test_marshal.rb +++ b/test/ruby/test_marshal.rb @@ -198,4 +198,10 @@ class TestMarshal < Test::Unit::TestCase assert_equal(sym, Marshal.load(Marshal.dump(sym)), '[ruby-core:24788]') end end + + ClassUTF8 = eval("class R\u{e9}sum\u{e9}; self; end") + def test_class_nonascii + a = ClassUTF8.new + assert_instance_of(ClassUTF8, Marshal.load(Marshal.dump(a)), '[ruby-core:24790]') + end end -- cgit