summaryrefslogtreecommitdiff
path: root/variable.c
diff options
context:
space:
mode:
authormatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2001-07-14 15:17:19 +0000
committermatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2001-07-14 15:17:19 +0000
commit03d1c9cd8238af6f1063ea4eb98d17fa2a511107 (patch)
treec4ee7cef5ccad7d2c73aa61eb586b3f68267699c /variable.c
parentf4b516777be7c1403deba3cfc653dcfb56f3d7f4 (diff)
* regex.c (re_search): should consider reverse search.
* dir.c (dir_s_chdir): warn only when invoked from multiple threads or block is not given. * object.c (rb_convert_type): should use rb_rescue(), not rb_rescue2(). * range.c (range_init): ditto. * object.c (rb_obj_dup): should free generic_ivar if original owns them. * string.c (rb_str_each_line): should propagate taint mark. * ext/nkf/nkf.c (rb_nkf_kconv): ditto. * eval.c (rb_f_require): revamp for simpler implementation. * file.c (rb_find_file_noext): use String object, instead of passing char* around. * file.c (rb_find_file): ditto. * dln.c (dln_load): should use NSLINKMODULE_OPTION_BINDNOW. * ruby.c (load_file): local variables 'c' remain uninitialized on xflag. * regex.c (re_match): prefetched escaped character too early. * eval.c (rb_call0): add argument check for attr_readers. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@1612 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'variable.c')
-rw-r--r--variable.c9
1 files changed, 3 insertions, 6 deletions
diff --git a/variable.c b/variable.c
index 23b246da004..79a11b76fee 100644
--- a/variable.c
+++ b/variable.c
@@ -142,9 +142,6 @@ classname(klass)
VALUE path = Qnil;
ID classpath = rb_intern("__classpath__");
- while (TYPE(klass) == T_ICLASS || FL_TEST(klass, FL_SINGLETON)) {
- klass = (VALUE)RCLASS(klass)->super;
- }
if (!klass) klass = rb_cObject;
if (!ROBJECT(klass)->iv_tbl)
ROBJECT(klass)->iv_tbl = st_init_numtable();
@@ -173,7 +170,7 @@ VALUE
rb_mod_name(mod)
VALUE mod;
{
- VALUE path = classname(mod);
+ VALUE path = classname(rb_obj_type(mod));
if (path) return rb_str_dup(path);
return rb_str_new(0,0);
@@ -183,7 +180,7 @@ VALUE
rb_class_path(klass)
VALUE klass;
{
- VALUE path = classname(klass);
+ VALUE path = classname(rb_class_real(klass));
if (path) return path;
else {
@@ -871,7 +868,7 @@ rb_free_generic_ivar(obj)
}
void
-rb_clone_generic_ivar(clone, obj)
+rb_copy_generic_ivar(clone, obj)
VALUE clone, obj;
{
st_table *tbl;