def drop_core

bend-collections@1.0.0.0 · src/containers/lru.bend:232

import bend-collections@1.0.0.0/src/containers/lru.bend as Lru
import Base

232# Unlink live slot s, free it and count it (c = 1 eviction, 2 removal); the
233# table is updated by the caller.
234def drop_core(a, -V: Kind(a), f: LRU<a, V>, +s: U32, +c: U32) -> LRU<a, V> & Maybe<a, V>:
235  F{+cap, +n, +head, +tail, +free, m, tab, ks, ents, lk} = f
236  drop_e(a, V, cap, n, head, tail, free, m, tab, ks, lk, s, c, Array.swap(Maybe<a, V>, ents, s, None{}))

Uses (6)

Used by (1)