def bytes.lane

gralha-bytes@0.1.0.1 · bytes.bend:15

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

15def bytes.lane(+index: U32) -> U32:
16  +k = U32.mod(index, 4)
17  U.choose(U32, U32.is_eq(k, 0), 1, U.choose(U32, U32.is_eq(k, 1), 256, U.choose(U32, U32.is_eq(k, 2), 65536, 16777216)))

Uses (4)

Used by (2)