mirror of
https://github.com/ruby/ruby.git
synced 2026-10-28 08:25:20 +08:00
Now that registrations are Ractor-scoped, a store of another Ractor's unshareable object through a registered address is a use-after-free waiting for the owner's next GC. This commit introduces a method to catch it in debug and ASAN builds by recording each VALUE at registration time so that when gc_verify_internal_consistency walks the registration list it can flag live, non-shareable values that are owned by a Ractor other than the registrant.