def bytes.be

gralha-bytes@0.1.0.1 · bytes.bend:84

import gralha-bytes@0.1.0.1/bytes.bend as Bytes
import Base

84def bytes.be(+bytes: Bytes, +at: U32, count: Nat, acc: U32) -> U32:
85  match count:
86    case 0n: acc
87    case 1n+d: bytes.be(bytes, U32.inc(at), d, (acc * 256 + bytes.get(bytes, at) : U32))

Uses (7)

Used by (13)