Dynamic array lengths are encoded as any other scalar, so when they're decoded/encoded we should
make sure they're read/written as little endian scalars. This change fixes the fact that converting binary
strings to/from ints assumes the string is in big endian representation, so arrays with max length over 256 would be incorrectly encoded.
Dynamic array lengths are encoded as any other scalar, so when they're decoded/encoded we should make sure they're read/written as little endian scalars. This change fixes the fact that converting binary strings to/from ints assumes the string is in big endian representation, so arrays with max length over 256 would be incorrectly encoded.