From: daniel@...42.com Date: 2020-12-02T14:52:05+00:00 Subject: [ruby-core:101204] [Ruby master Bug#17360] Objects disappear from ObjectSpace after using Ractor Issue #17360 has been reported by Dan0042 (Daniel DeLorme). ---------------------------------------- Bug #17360: Objects disappear from ObjectSpace after using Ractor https://bugs.ruby-lang.org/issues/17360 * Author: Dan0042 (Daniel DeLorme) * Status: Open * Priority: Normal * Backport: 2.5: UNKNOWN, 2.6: UNKNOWN, 2.7: UNKNOWN ---------------------------------------- Test: ```ruby GC.disable STR = -"testing 123" x = STR.dup puts "before:" ObjectSpace.each_object(String){ |s| puts s.object_id if s == STR } Ractor.new{ }.take puts "after:" ObjectSpace.each_object(String){ |s| puts s.object_id if s == STR } ``` Result: ``` before: 60 80 100 :38: warning: Ractor is experimental, and the behavior may change in future versions of Ruby! Also there are many implementation issues. after: 80 ``` Expected result: Same object ids should be printed before and after (BTW why 3 strings with the same value? shouldn't it be 2?) -- https://bugs.ruby-lang.org/ Unsubscribe: