ruby-core@ruby-lang.org archive (unofficial mirror)
 help / color / mirror / Atom feed
* [ruby-core:98118] [Ruby master Bug#16826] ObjectSpace::WeakMap#key? returns false if value is nil
@ 2020-05-02 13:17 eregontp
  2020-05-02 14:06 ` [ruby-core:98119] " eregontp
  2020-07-23  4:51 ` [ruby-core:99288] " nagachika00
  0 siblings, 2 replies; 3+ messages in thread
From: eregontp @ 2020-05-02 13:17 UTC (permalink / raw)
  To: ruby-core

Issue #16826 has been reported by Eregon (Benoit Daloze).

----------------------------------------
Bug #16826: ObjectSpace::WeakMap#key? returns false if value is nil
https://bugs.ruby-lang.org/issues/16826

* Author: Eregon (Benoit Daloze)
* Status: Open
* Priority: Normal
* 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/

^ permalink raw reply	[flat|nested] 3+ messages in thread

* [ruby-core:98119] [Ruby master Bug#16826] ObjectSpace::WeakMap#key? returns false if value is nil
  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
  2020-07-23  4:51 ` [ruby-core:99288] " nagachika00
  1 sibling, 0 replies; 3+ messages in thread
From: eregontp @ 2020-05-02 14:06 UTC (permalink / raw)
  To: ruby-core

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/

^ permalink raw reply	[flat|nested] 3+ messages in thread

* [ruby-core:99288] [Ruby master Bug#16826] ObjectSpace::WeakMap#key? returns false if value is nil
  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 ` [ruby-core:98119] " eregontp
@ 2020-07-23  4:51 ` nagachika00
  1 sibling, 0 replies; 3+ messages in thread
From: nagachika00 @ 2020-07-23  4:51 UTC (permalink / raw)
  To: ruby-core

Issue #16826 has been updated by nagachika (Tomoyuki Chikanaga).

Backport changed from 2.5: DONTNEED, 2.6: DONTNEED, 2.7: REQUIRED to 2.5: DONTNEED, 2.6: DONTNEED, 2.7: DONE

ruby_2_7 9da6470d7b3aa136b4b92469c8bbc522beb1ac31 merged revision(s) a2be428c5fec31b8adbd5ac087e7637ddf7e54d0.

----------------------------------------
Bug #16826: ObjectSpace::WeakMap#key? returns false if value is nil
https://bugs.ruby-lang.org/issues/16826#change-86677

* Author: Eregon (Benoit Daloze)
* Status: Closed
* 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: DONE
----------------------------------------
```
$ 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/

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2020-07-23  4:51 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
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 ` [ruby-core:98119] " eregontp
2020-07-23  4:51 ` [ruby-core:99288] " nagachika00

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).