ubyte[] bigIntToBytes(BigInt val)
Converts a non-negative BigInt to minimal big-endian unsigned bytes.