def recycle_slot

bend-collections@1.0.0.0 · src/containers/internal/dlist_storage.bend:570

import bend-collections@1.0.0.0/src/containers/internal/dlist_storage.bend as DlistStorage
import Base

570# Called only after a successful remove, by an owner that invalidated the
571# removed handle's generation. The slot is already absent from the live list.
572def recycle_slot(~T: Data, s: DList<T>, +i: U32) -> DList<T>:
573  DL{tag, fresh, +free, count, head, tail, depth, cap, vals, prevs, nexts} = s
574  DL{tag, fresh, link(i), count, head, tail, depth, cap, vals, prevs, Array.set(U32, nexts, i, free)}

Uses (4)

Used by (1)