From: nobu@ruby-lang.org
To: ruby-core@ruby-lang.org
Subject: [ruby-core:91507] [Ruby trunk Bug#15597] syscall not returning true from private_method_defined?
Date: Mon, 11 Feb 2019 06:57:43 +0000 (UTC) [thread overview]
Message-ID: <redmine.journal-76768.20190211065742.7b9461657ab403bf@ruby-lang.org> (raw)
In-Reply-To: redmine.issue-15597.20190210202856@ruby-lang.org
Issue #15597 has been updated by nobu (Nobuyoshi Nakada).
Status changed from Open to Feedback
What is your OS?
Doesn't `syscall` method always raise a `NotImplementedError`?
----------------------------------------
Bug #15597: syscall not returning true from private_method_defined?
https://bugs.ruby-lang.org/issues/15597#change-76768
* Author: AaronLasseigne (Aaron Lasseigne)
* Status: Feedback
* Priority: Normal
* Assignee:
* Target version:
* ruby -v:
* Backport: 2.4: UNKNOWN, 2.5: UNKNOWN, 2.6: UNKNOWN
----------------------------------------
`syscode` is a private method on `Object` but when checked with `private_method_defined?` it returns `false`.
Ruby 2.6.1
```
irb(main):001:0> Object.new.private_methods.sort.select { |pm| !Object.private_method_defined?(pm) }
=> [:syscall]
```
Ruby 2.5.3
```
irb(main):001:0> Object.new.private_methods.sort.select { |pm| !Object.private_method_defined?(pm) }
=> []
```
--
https://bugs.ruby-lang.org/
next prev parent reply other threads:[~2019-02-11 6:57 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <redmine.issue-15597.20190210202856@ruby-lang.org>
2019-02-10 20:28 ` [ruby-core:91505] [Ruby trunk Bug#15597] syscall not returning true from private_method_defined? aaron.lasseigne
2019-02-11 6:57 ` nobu [this message]
2019-02-13 4:44 ` [ruby-core:91527] " aaron.lasseigne
2019-02-13 14:57 ` [ruby-core:91531] " hanmac
2019-02-14 4:13 ` [ruby-core:91541] " nobu
2019-02-14 12:30 ` [ruby-core:91547] " hanmac
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-76768.20190211065742.7b9461657ab403bf@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).