racket
racket copied to clipboard
[Feature Request] Weak Vectors
Weak vectors are useful for maintaining pools of objects who's finalisers interact with other live objects in the pool. For example, compacting or reordering slots which become free due to the underlying object being unreachable. Or managing pools of objects in an FFI context.
Currently you can create a vector of weak pairs, but this adds an extra level of indirection and memory usage for no benefit.