Releases: denostack/weakref
Releases · denostack/weakref
0.2.3
Bug Fixes
- WeakValueMap: fix overwrite existing key (#1) — When overwriting an existing key with
set(), the previous WeakRef's FinalizationRegistry was not unregistered, causing the new value to be deleted unexpectedly. - Fix accessors returning stale state before FinalizationRegistry fires (#2) — After a value was garbage-collected but before the FinalizationRegistry callback ran,
get(),has(), and iterators would returnundefinedinstead of treating the entry as absent. Applied lazy cleanup on access toWeakValueMap,IterableWeakSet, andIterableWeakMap.