From: matz@ruby.or.jp
To: ruby-core@ruby-lang.org
Subject: [ruby-core:103472] [Ruby master Bug#9542] Delegator does not delegate protected methods
Date: Fri, 16 Apr 2021 05:44:54 +0000 (UTC) [thread overview]
Message-ID: <redmine.journal-91569.20210416054454.7882@ruby-lang.org> (raw)
In-Reply-To: redmine.issue-9542.20140220163540.7882@ruby-lang.org
Issue #9542 has been updated by matz (Yukihiro Matsumoto).
Backport deleted (1.9.3: UNKNOWN, 2.0.0: UNKNOWN, 2.1: UNKNOWN)
It's intentional.
Matz.
----------------------------------------
Bug #9542: Delegator does not delegate protected methods
https://bugs.ruby-lang.org/issues/9542#change-91569
* Author: vrinek (Konstantinos Karachalios)
* Status: Open
* Priority: Normal
* ruby -v: 2.1.0p0
----------------------------------------
The Delegator of the "delegate" standard library has changed its behaviour since 2.0 because of the change in "respond_to?" concerning protected methods.
As of ruby 2.0, Delegator does not delegate protected methods any more.
In case this is indeed a bug, I will prepare a pull request on github fixing the issue.
On the other hand, if is intentional behaviour, something has to change in the documentation for "delegate" as well as [Delegator#respond_to_missing?](http://ruby-doc.org/stdlib-2.1.0/libdoc/delegate/rdoc/Delegator.html#method-i-respond_to_missing-3F) (at least the second argument's name). I can help with the code but I am not so confident in my documentation skills.
---Files--------------------------------
the_bug.rb (283 Bytes)
output.txt (589 Bytes)
--
https://bugs.ruby-lang.org/
parent reply other threads:[~2021-04-16 5:45 UTC|newest]
Thread overview: expand[flat|nested] mbox.gz Atom feed
[parent not found: <redmine.issue-9542.20140220163540.7882@ruby-lang.org>]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-list from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.ruby-lang.org/en/community/mailing-lists/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=redmine.journal-91569.20210416054454.7882@ruby-lang.org \
--to=ruby-core@ruby-lang.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).