diff options
author | drbrain <drbrain@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2012-05-22 20:15:28 +0000 |
---|---|---|
committer | drbrain <drbrain@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2012-05-22 20:15:28 +0000 |
commit | 1d4e7d923266090844ef1bc1afc8704b75b7d057 (patch) | |
tree | f52885586dba38fce3933298d629d9d35e62a03a /class.c | |
parent | cb61ea5ef3aee59c0c5026c113ef5954992f7ca1 (diff) | |
download | ruby-1d4e7d923266090844ef1bc1afc8704b75b7d057.tar.gz |
* class.c (rb_mod_init_copy): Clear the cached inspect string of a
dup'd anonymous module or class. [ruby-trunk - Bug #6454]
* test/ruby/test_module.rb (class TestModule): ditto
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@35759 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'class.c')
-rw-r--r-- | class.c | 2 |
1 files changed, 2 insertions, 0 deletions
@@ -174,6 +174,8 @@ rb_mod_init_copy(VALUE clone, VALUE orig) st_free_table(RCLASS_IV_TBL(clone)); } RCLASS_IV_TBL(clone) = st_copy(RCLASS_IV_TBL(orig)); + CONST_ID(id, "__tmp_classpath__"); + st_delete(RCLASS_IV_TBL(clone), &id, 0); CONST_ID(id, "__classpath__"); st_delete(RCLASS_IV_TBL(clone), &id, 0); CONST_ID(id, "__classid__"); |