def all_bytes

lawful-bytes@0.1.1.0 · defs.bend:45

import lawful-bytes@0.1.1.0/defs.bend as Defs
import Base

45# Every element is a byte (below 256).
46def all_bytes(xs: List<&2, U32>) -> Bool:
47  match xs:
48    case Nil{}:
49      True{}
50    case Con{x, t}:
51      U32.is_lt(x, 256) && all_bytes(t)

Uses (5)

Used by (11)