def kx_go

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

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

817def kx_go(a, -V: Kind(a), fuel: Nat, +now: W.U64, s: Kx<a, V>) -> LRU<a, V>:
818  match fuel s:
819    case 0n KMore{f}:
820      f
821    case 0n KDone{f}:
822      f
823    case 1n+p KMore{f}:
824      kx_go(a, V, p, now, kx_check(a, V, drop_head(a, V, f), now))
825    case 1n+p KDone{f}:
826      f

Uses (6)

Used by (1)