From 02337b089e76a70ffc269beda8d778a175d575d3 Mon Sep 17 00:00:00 2001 From: nobu Date: Wed, 18 Jun 2008 03:05:33 +0000 Subject: * marshal.c (w_object, marshal_dump, r_object0, marshal_load): search public methods only. [ruby-core:17283] * object.c (convert_type): ditto. * lib/singleton.rb (Singleton#_dump): conversion method should be public. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@17396 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- object.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'object.c') diff --git a/object.c b/object.c index 0d18ea5b29..e4f513763e 100644 --- a/object.c +++ b/object.c @@ -1904,7 +1904,7 @@ convert_type(VALUE val, const char *tname, const char *method, int raise) ID m; m = rb_intern(method); - if (!rb_obj_respond_to(val, m, Qtrue)) { + if (!rb_respond_to(val, m)) { if (raise) { rb_raise(rb_eTypeError, "can't convert %s into %s", NIL_P(val) ? "nil" : -- cgit v1.2.3