Change ibc::apps::transfer::types::Memo type to wrap Vec<u8> rather than a String so that it doesn’t have to be valid UTF-8. With ICS-20 memo is used to transfer machine-readable instructions to execute after a transfer. However, the field being a String forces them to be valid UTF-8. In some situations, this prevents most efficient memo representation to be used.
For example, on Ethereum one might define memo to use/include Ethereum ABI encoded function call but to be able to include that in memo it must be UTF-8 which forces users to waste time and space doing hex or base64 encoding.
Notably, in Proto converting string field into bytes is backwards compatible. Furthermore, Go (as far as I know) accepts invalid encoding within string type.
Change ibc::apps::transfer::types::Memo type to wrap
Vec<u8>
rather than aString
so that it doesn’t have to be valid UTF-8. With ICS-20 memo is used to transfer machine-readable instructions to execute after a transfer. However, the field being a String forces them to be valid UTF-8. In some situations, this prevents most efficient memo representation to be used.For example, on Ethereum one might define memo to use/include Ethereum ABI encoded function call but to be able to include that in memo it must be UTF-8 which forces users to waste time and space doing hex or base64 encoding.
Notably, in Proto converting string field into bytes is backwards compatible. Furthermore, Go (as far as I know) accepts invalid encoding within string type.