Module bytes_to_fields
Functions
- Converts an input BoundedVec of fields into a BoundedVec of bytes in big-endian order. Arbitrary Field arrays are not allowed: this is assumed to be an array obtained via
bytes_to_fields, i.e. one that actually represents bytes. To convert a Field array into bytes, usefields_to_bytes. - Converts the input bytes into an array of fields. A Field is ~254 bits meaning that each field can store 31 whole bytes. Use
bytes_from_fieldsto obtain the original bytes array.