diff options
author | ko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2013-10-11 18:03:43 +0000 |
---|---|---|
committer | ko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2013-10-11 18:03:43 +0000 |
commit | 9d70a17541782493c7cf5d0dceafadccc2424bd8 (patch) | |
tree | 746711090e8743e238e636cec88eab54064091cd /variable.c | |
parent | 3b0abede8ef1a89c4798be11c46922924e21484e (diff) | |
download | ruby-9d70a17541782493c7cf5d0dceafadccc2424bd8.tar.gz |
revert r43259 because it is possible to mark miss classes defined in C-exts. Thanks charliesome.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@43261 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'variable.c')
-rw-r--r-- | variable.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/variable.c b/variable.c index fa4a769b33..3b3189bddc 100644 --- a/variable.c +++ b/variable.c @@ -21,12 +21,14 @@ #include "id.h" st_table *rb_global_tbl; +st_table *rb_class_tbl; static ID autoload, classpath, tmp_classpath, classid; void Init_var_tables(void) { rb_global_tbl = st_init_numtable(); + rb_class_tbl = st_init_numtable(); CONST_ID(autoload, "__autoload__"); /* __classpath__: fully qualified class path */ CONST_ID(classpath, "__classpath__"); @@ -133,6 +135,9 @@ find_class_path(VALUE klass, ID preferred) if (RCLASS_CONST_TBL(rb_cObject)) { st_foreach_safe(RCLASS_CONST_TBL(rb_cObject), fc_i, (st_data_t)&arg); } + if (arg.path == 0) { + st_foreach_safe(rb_class_tbl, fc_i, (st_data_t)&arg); + } if (arg.path) { st_data_t tmp = tmp_classpath; if (!RCLASS_IV_TBL(klass)) { |