Lru.resize_go: def of bend-collections@1.0.0.0
Import: import bend-collections@1.0.0.0/src/containers/lru.bend as Lru
Lines 767-772 of bend-collections@1.0.0.0/src/containers/lru.bend: https://jend.leeeet.dev/read.txt?path=bend-collections@1.0.0.0/src/containers/lru.bend&start_line=767&end_line=772
import Base
def resize_go(a, -V: Kind(a), f: LRU, +cap: U32, zero: Bool) -> LRU & Result<&2, &2, String, U32>:
match zero:
case True{}:
(f, Fail{"capacity must be positive"})
case False{}:
rz_start(a, V, set_cap(a, V, f, cap))
Uses (9):
https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Bool
https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Pair
https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Result
https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Sigma
https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=String
https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32
https://jend.leeeet.dev/definition.txt?path=bend-collections@1.0.0.0/src/containers/lru.bend&name=LRU
https://jend.leeeet.dev/definition.txt?path=bend-collections@1.0.0.0/src/containers/lru.bend&name=rz_start
https://jend.leeeet.dev/definition.txt?path=bend-collections@1.0.0.0/src/containers/lru.bend&name=set_cap