From 5bf72d1fa60e195641cb9347c5e5bd98e85da72e Mon Sep 17 00:00:00 2001 From: nobu Date: Tue, 7 Dec 2010 13:05:26 +0000 Subject: * transcode.c (transcode_loop): call default handler of the given hash, method, proc or [] method as fallback. [ruby-dev:42692] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@30118 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- proc.c | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'proc.c') diff --git a/proc.c b/proc.c index 0489dd967f..9ecf62656e 100644 --- a/proc.c +++ b/proc.c @@ -28,7 +28,6 @@ VALUE rb_iseq_parameters(const rb_iseq_t *iseq, int is_proc); static VALUE bmcall(VALUE, VALUE); static int method_arity(VALUE); -static int rb_obj_is_method(VALUE m); rb_iseq_t *rb_method_get_iseq(VALUE method); /* Proc */ @@ -893,10 +892,15 @@ static const rb_data_type_t method_data_type = { }, }; -static inline int +VALUE rb_obj_is_method(VALUE m) { - return rb_typeddata_is_kind_of(m, &method_data_type); + if (rb_typeddata_is_kind_of(m, &method_data_type)) { + return Qtrue; + } + else { + return Qfalse; + } } static VALUE -- cgit v1.2.3