From: eregontp@gmail.com
To: ruby-core@ruby-lang.org
Subject: [ruby-core:98119] [Ruby master Bug#16826] ObjectSpace::WeakMap#key? returns false if value is nil
Date: Sat, 02 May 2020 14:06:21 +0000 (UTC) [thread overview]
Message-ID: <redmine.journal-85360.20200502140621.772@ruby-lang.org> (raw)
In-Reply-To: redmine.issue-16826.20200502131741.772@ruby-lang.org
Issue #16826 has been updated by Eregon (Benoit Daloze).
Assignee set to Eregon (Benoit Daloze)
I'll fix this.
----------------------------------------
Bug #16826: ObjectSpace::WeakMap#key? returns false if value is nil
https://bugs.ruby-lang.org/issues/16826#change-85360
* Author: Eregon (Benoit Daloze)
* Status: Open
* Priority: Normal
* Assignee: Eregon (Benoit Daloze)
* ruby -v: ruby 2.7.1p83 (2020-03-31 revision a0c7c23c9c) [x86_64-linux]
* Backport: 2.5: DONTNEED, 2.6: DONTNEED, 2.7: REQUIRED
----------------------------------------
```
$ ruby -e 'map=ObjectSpace::WeakMap.new; map[:foo] = 4; p map; p map.key? :foo'
#<ObjectSpace::WeakMap:0x000055fbe0c38c00: :foo => 4>
true # OK
$ ruby -e 'map=ObjectSpace::WeakMap.new; map[:foo] = nil; p map; p map.key? :foo'
#<ObjectSpace::WeakMap:0x000056371e3f86e8: :foo => nil>
false # BUG
```
--
https://bugs.ruby-lang.org/
next prev parent reply other threads:[~2020-05-02 14:06 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-05-02 13:17 [ruby-core:98118] [Ruby master Bug#16826] ObjectSpace::WeakMap#key? returns false if value is nil eregontp
2020-05-02 14:06 ` eregontp [this message]
2020-07-23 4:51 ` [ruby-core:99288] " nagachika00
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-85360.20200502140621.772@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).