def bytes.interval.length

mylsm-lsm-store@0.6.0.1 · src/ByteWal.bend:167

import mylsm-lsm-store@0.6.0.1/src/ByteWal.bend as ByteWal
import Base

167# Checks that a byte interval lies within its source frame.
168# Checks a byte interval against the source length.
169def bytes.interval.length(total: U32, start: U32, length: U32) -> Bool:
170  Nat.is_le(Nat.add(U32.to_nat(start), U32.to_nat(length)), U32.to_nat(total))

Uses (5)

Used by (6)