def suffix
import bend-collections@1.0.0.0/src/crypto/sha512/core.bend as Coreimport Base
157# 0x80, zeros up to 112 mod 128, then the 128-bit bit length.
158def suffix(+n: Nat) -> List<&2, U32>:
159 128 <> List.append(&2, U32, List.replicate(U32, zeros(Nat.mod(n, 128n)), 0), bit_length(n))