super_method fails on binded/unbinded/cloned methods
derived from #13973:
module A def foo end end module B def foo end end class C include A include B end c = C.new m1 = c.method(:foo) p m1.super_method # => #<Method: A#foo> p m1.clone.super_method # => nil p m1.unbind.super_method # => nil m2 = C.instance_method(:foo) p m2.super_method # => #<UnboundMethod: A#foo> p m2.clone.super_method # => nil p m2.bind(c).super_method # => nil
super_method of binded/unbinded/cloned method should be
super_method of original method, shouldn't it?
Updated by jeremyevans0 (Jeremy Evans) 2 months ago
This bug is due to the fact that bind/unbind/clone do not copy the
iclass entry, and without an
nil. Attached is a patch that fixes this issue.
Updated by jeremyevans (Jeremy Evans) 2 days ago
- Status changed from Open to Closed