Issue #19411 has been updated by luke-gru (Luke Gruber).
The issue is again with shapes (related to
https://bugs.ruby-lang.org/issues/19409). Newly
moved objects (class MovedObject) need to have their shape reset to root shape. I'll
make a PR for this.
----------------------------------------
Bug #19411: GC issue with moved objects
https://bugs.ruby-lang.org/issues/19411#change-101641
* Author: luke-gru (Luke Gruber)
* Status: Open
* Priority: Normal
* ruby -v: 3.2.0
* Backport: 2.7: UNKNOWN, 3.0: UNKNOWN, 3.1: UNKNOWN, 3.2: UNKNOWN
----------------------------------------
This crashes:
```ruby
class Obj
def initialize
@obj = 3
end
end
GC.stress = true
r = Ractor.new do
obj = receive
p obj
end
obj = Obj.new
r.send(obj, move: true)
r.take
```
It only crashes with nested objects, if you remove the ivar set in `initialize` it works
fine. Maybe missing `RB_GC_GUARD`?
--
https://bugs.ruby-lang.org/