def read.if

bend-kit-bits@0.1.0.1 · bits.bend:63

import bend-kit-bits@0.1.0.1/bits.bend as Bits
import Base

63def read.if(ok: Bool, +msb: Bool, +len: U32, buf: Array<U32>, +pos: U32, +n: U32) -> Reader & Maybe<&2, U32>:
64  match ok:
65    case True{}:
66      read.got(msb, len, pos, n, win(msb, buf, pos))
67    case False{}:
68      (Reader{len, buf, pos}, None{})

Uses (9)

Used by (1)