def rotate_if

bend-collections-laws-crypto@1.0.0.0 · src/crypto/keccak/lane.bend:16

import bend-collections-laws-crypto@1.0.0.0/src/crypto/keccak/lane.bend as Lane
import Base
import bend-collections-laws-crypto@1.0.0.0/src/crypto/keccak/types.bend as T

16def rotate_if(lo: U32, hi: U32, +n: Nat, b: Bool) -> T.Lane:
17  match b:
18    case True{}: small(lo,hi,n)
19    case False{}: small(hi,lo,Nat.sub(n,32n))

Uses (6)

Used by (1)