From 44f7a34031fd02bcb740c7ca6afa19274531c7c1 Mon Sep 17 00:00:00 2001 From: nobu Date: Fri, 25 Sep 2009 03:33:26 +0000 Subject: * vm_method.c (obj_respond_to_missing): added rdoc. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@25087 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- vm_method.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'vm_method.c') diff --git a/vm_method.c b/vm_method.c index 014840d7d6..0db125bb15 100644 --- a/vm_method.c +++ b/vm_method.c @@ -1163,6 +1163,9 @@ rb_respond_to(VALUE obj, ID id) * If the method is not implemented, * as Process.fork on Windows, File.lchmod on GNU/Linux, etc., * false is returned. + * + * If the method is not defined, respond_to_missing? + * method is called and the result is returned. */ static VALUE @@ -1178,6 +1181,15 @@ obj_respond_to(int argc, VALUE *argv, VALUE obj) return Qfalse; } +/* + * call-seq: + * obj.respond_to_missing?(symbol, include_private=false) => true or false + * + * Hook method to return whether the _obj_ can respond to _id_ method + * or not. + * + * See #respond_to?. + */ static VALUE obj_respond_to_missing(int argc, VALUE *argv, VALUE obj) { -- cgit v1.2.3