You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When I compiled my code which contains a smart contract invocation, I got a following error.
error[E0277]: the trait bound `([web3::types::H160; 3], [web3::types::U128; 8], [web3::types::U256; 6], [web3::types::H256; 5], std::string::String): web3::contract::tokens::Tokenize` is not satisfied
--> src/bin/call_func.rs:69:51
|
69 | let call_future = contract.call("test", (
| ___________________________________________________^
70 | | ary1,
71 | | ary2,
72 | | ary3,
73 | | ary4,
74 | | "test_text".to_string(),
75 | | ), owner_address, write_options);
| |_____^ the trait `web3::contract::tokens::Tokenize` is not implemented for `([web3::types::H160; 3], [web3::types::U128; 8], [web3::types::U256; 6], [web3::types::H256; 5], std::string::String)`
|
= help: the following implementations were found:
<(A, B, C, D, E) as web3::contract::tokens::Tokenize>
error: aborting due to previous error
For more information about this error, try `rustc --explain E0277`.
error: could not compile `relayer`.
To learn more, run the command again with --verbose.
However, when I change ary3 length from 6 to 8, the compile went well.
Does the array length affect to the compile result?
Thank you
The text was updated successfully, but these errors were encountered:
Yeah, unfortunately Rust requires us to implement this trait manually for every size and it was only implemented for 5 and then 8 and 16. I've added implementations for up to 16 elements and then power of two in #307
Hi,
When I compiled my code which contains a smart contract invocation, I got a following error.
However, when I change
ary3
length from 6 to 8, the compile went well.Does the array length affect to the compile result?
Thank you
The text was updated successfully, but these errors were encountered: