def stream.result.lengths

mylsm-lsm-store@0.6.0.1 · src/hub_sha/sha256.bend:297

import mylsm-lsm-store@0.6.0.1/src/hub_sha/sha256.bend as Sha256
import Base
import mylsm-lsm-store@0.6.0.1/src/hub_sha/state.bend as S
import bend-kit-bytes@0.3.2.0/bytes.bend as Packed

297def stream.result.lengths(
298  +compressed: S.State,
299  joined: Packed.Bytes,
300  lengths: Nat & Nat,
301  remainder: Nat,
302  total: Nat
303) -> Result<&1, &1, StreamError, Stream>:
304  match lengths:
305    case (for_slice, for_result):
306      stream.result.sliced(compressed,
307        Packed.slice(joined, 0, U32.from_nat(for_slice)), for_result,
308        remainder, total)

Uses (11)

Used by (1)