summaryrefslogtreecommitdiff
path: root/marshal.c
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2004-10-18 14:37:42 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2004-10-18 14:37:42 +0000
commite49259f772a40ca530adba5ffb8c84f98c7d4323 (patch)
treeb8966b0da606dc47af57ba410a430d316972c9b0 /marshal.c
parent9146e09a4fcecda9420ff8f18d78241791b9d871 (diff)
* marshal.c (r_object0): check inheritance by the internal function.
[ruby-dev:24515] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@7063 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'marshal.c')
-rw-r--r--marshal.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/marshal.c b/marshal.c
index 71c6d16..5323fdd 100644
--- a/marshal.c
+++ b/marshal.c
@@ -1050,7 +1050,7 @@ r_object0(arg, proc, ivp, extmod)
format_error:
rb_raise(rb_eArgError, "dump format error (user class)");
}
- if (TYPE(v) == T_MODULE || !RTEST(rb_funcall(c, '<', 1, RBASIC(v)->klass))) {
+ if (TYPE(v) == T_MODULE || !RTEST(rb_class_inherited_p(c, RBASIC(v)->klass))) {
VALUE tmp = rb_obj_alloc(c);
if (TYPE(v) != TYPE(tmp)) goto format_error;