You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Mustermann::EqualityMap uses ObjectSpace::WeakMap directly in its implementation. According to the docs for ObjectSpace::WeakMap, that class should not be used directly:
This class is mostly used internally by WeakRef, please use lib/weakref.rb for the public interface.
Of course, it exists and works, but using WeakRef instead looks like the safer option.
The text was updated successfully, but these errors were encountered:
I think that means you're relying on implementation details. TruffleRuby's WeakRef has a different implementation that adheres to the interface, for instance. We don't currently have ObjectSpace::WeakMap, so we fall back to the Array implementation in Mustermann. We'll add ObjectSpace::WeakMap, but this caught my eye as an issue that could also be addressed by using the suggested public interface.
Mustermann::EqualityMap
usesObjectSpace::WeakMap
directly in its implementation. According to the docs for ObjectSpace::WeakMap, that class should not be used directly:Of course, it exists and works, but using
WeakRef
instead looks like the safer option.The text was updated successfully, but these errors were encountered: