[ruby-core:94541] [Ruby master Bug#16127] Delegates to BasicObject do not work

[email protected]
Newsgroups gmane.comp.lang.ruby.core
Message-ID <redmine.issue-16127.20190825071038.8672930e76402020@ruby-lang.org>
Issue #16127 has been reported by jeremyevans0 (Jeremy Evans).

----------------------------------------
Bug #16127: Delegates to BasicObject do not work
https://bugs.ruby-lang.org/issues/16127

* Author: jeremyevans0 (Jeremy Evans)
* Status: Open
* Priority: Normal
* Assignee: 
* Target version: 
* ruby -v: ruby 2.7.0dev (2019-08-25) [x86_64-openbsd6.5]
* Backport: 2.5: UNKNOWN, 2.6: UNKNOWN
----------------------------------------
The delegate library does not currently handle BasicObject targets, since it assumes the target responds to `respond_to?`.  The attached patch works around the issue by binding the Kernel `respond_to?` instance method to the target and then calling that.


---Files--------------------------------
delegate-basicobject.patch (2.29 KB)


-- 
https://bugs.ruby-lang.org/

Unsubscribe: <mailto:[email protected]?subject=unsubscribe>
<http://lists.ruby-lang.org/cgi-bin/mailman/options/ruby-core>
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.