diff options
-rw-r--r-- | ChangeLog | 5 | ||||
-rw-r--r-- | vm_method.c | 2 |
2 files changed, 6 insertions, 1 deletions
@@ -1,3 +1,8 @@ +Fri Oct 9 23:10:04 2009 Yukihiro Matsumoto <matz@ruby-lang.org> + + * vm_method.c (rb_method_boundp): should exclude NOEX_RESPONDS. + based on the patch from Nikolai Lugovoi. [ruby-core:25949] + Fri Oct 9 21:14:40 2009 Tanaka Akira <akr@fsij.org> * lib/resolv.rb (Resolv::DNS::Requester::ConnectedUDP): disable diff --git a/vm_method.c b/vm_method.c index a31fb8b5ac..bed8e61bd6 100644 --- a/vm_method.c +++ b/vm_method.c @@ -512,7 +512,7 @@ rb_method_boundp(VALUE klass, ID id, int ex) rb_method_entry_t *me = rb_method_entry(klass, id); if (me != 0) { - if (ex && (me->flag & NOEX_PRIVATE)) { + if ((ex & ~NOEX_RESPONDS) && (me->flag & NOEX_PRIVATE)) { return FALSE; } if (!me->def) return 0; |