summaryrefslogtreecommitdiff
path: root/eval.c
diff options
context:
space:
mode:
authormatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2001-12-18 08:40:33 +0000
committermatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2001-12-18 08:40:33 +0000
commit74097260aeac51cb2839d90f5cf7eb4c84c9124f (patch)
tree4b2f781b6af183d2eb4bab2fce876d6addc021d3 /eval.c
parentb49f3b26e5d96c22f3ccb578a5bef3dbff8f7dba (diff)
* eval.c (rb_thread_schedule): should not select a thread which is
not yet initialized. * variable.c (find_class_path): should initialize iv_tbl if it's NULL. * class.c (rb_define_class): should return the existing class if the class is already defined and its superclass is ideintical to the specified superclass. * class.c (rb_define_class_under): ditto. * class.c (rb_define_module): should return the existing module if the module is already defined. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_6@1917 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'eval.c')
-rw-r--r--eval.c10
1 files changed, 2 insertions, 8 deletions
diff --git a/eval.c b/eval.c
index 7ee5d5ed5e..60ca4f7831 100644
--- a/eval.c
+++ b/eval.c
@@ -3082,13 +3082,7 @@ rb_eval(self, n)
rb_id2name(node->nd_cname));
}
if (super) {
- tmp = RCLASS(klass)->super;
- if (FL_TEST(tmp, FL_SINGLETON)) {
- tmp = RCLASS(tmp)->super;
- }
- while (TYPE(tmp) == T_ICLASS) {
- tmp = RCLASS(tmp)->super;
- }
+ tmp = rb_class_real(RCLASS(klass)->super);
if (tmp != super) {
goto override_class;
}
@@ -7650,7 +7644,7 @@ rb_thread_schedule()
next = th;
break;
}
- if (th->status == THREAD_RUNNABLE) {
+ if (th->status == THREAD_RUNNABLE && th->stk_ptr) {
if (!next || next->priority < th->priority)
next = th;
}