def word_bytes

bend-collections@1.0.0.0 · src/crypto/secp256k1.bend:50

import bend-collections@1.0.0.0/src/crypto/secp256k1.bend as Secp256k1
import Base

50def word_bytes(+w: U32, rest: List<&2, U32>) -> List<&2, U32>:
51  U32.and(w, 255) <> U32.and(U32.shrn(w, 8n), 255) <> U32.and(U32.shrn(w, 16n), 255) <> U32.shrn(w, 24n) <> rest

Uses (4)

Used by (1)