def split

bend-collections@1.0.0.0 · src/crypto/poly1305/limbs.bend:75

import bend-collections@1.0.0.0/src/crypto/poly1305/limbs.bend as Limbs
import Base

75# Limb n (the top one) reduced to its low 2 bits, i.e. the value below 2^130
76# when n = 16; quot is the rest of limb n, the multiple of 2^130.
77def split(n: Nat, +xs: List<&2, U32>) -> List<&2, U32>:
78  match n:
79    case 0n: [U32.and(hd0(xs), 3)]
80    case 1n+k: hd0(xs) <> split(k, tl(xs))

Uses (6)

Used by (1)