Redis.read.n: def of bend-kit-redis@0.3.1.0 Import: import bend-kit-redis@0.3.1.0/redis.bend as Redis Lines 812-828 of bend-kit-redis@0.3.1.0/redis.bend: https://jend.leeeet.dev/read.txt?path=bend-kit-redis@0.3.1.0/redis.bend&start_line=812&end_line=828 import Base # n more replies onto the reversed list in st. def read.n(n: Nat, st: Result<&1, &1, Failure, Conn & List<&1, Val>>) -> IO(Result<&1, &1, Failure, Conn & List<&1, Val>>): match n: case 0n: match st: case Fail{e}: IO.pure(Result<&1, &1, Failure, Conn & List<&1, Val>>, Fail{e}) case Done{(c, xs)}: IO.pure(Result<&1, &1, Failure, Conn & List<&1, Val>>, Done{(c, List.reverse(&1, Val, xs))}) case 1n+p: match st: case Fail{e}: IO.pure(Result<&1, &1, Failure, Conn & List<&1, Val>>, Fail{e}) case Done{(c, xs)}: do IO>>: r : Result<&1, &1, Failure, Conn & Val> <- read(c) read.n(p, read.push(xs, r)) Uses (14): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=IO https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=IO.bind https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=IO.pure https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=List https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=List.reverse https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Nat 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=bend-kit-redis@0.3.1.0/redis.bend&name=Conn https://jend.leeeet.dev/definition.txt?path=bend-kit-redis@0.3.1.0/redis.bend&name=Failure https://jend.leeeet.dev/definition.txt?path=bend-kit-redis@0.3.1.0/redis.bend&name=Val https://jend.leeeet.dev/definition.txt?path=bend-kit-redis@0.3.1.0/redis.bend&name=read https://jend.leeeet.dev/definition.txt?path=bend-kit-redis@0.3.1.0/redis.bend&name=read.push