Skip to content

Commit

Permalink
fix(json-abi): fallback to tuple types for nested params in to_sol
Browse files Browse the repository at this point in the history
  • Loading branch information
DaniPopes committed Oct 9, 2023
1 parent 6017a8b commit 7a55e0a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions crates/json-abi/src/to_sol.rs
Original file line number Diff line number Diff line change
Expand Up @@ -384,8 +384,8 @@ fn param<'a>(
// See https://github.com/alloy-rs/core/issues/349
Some(rest) if rest.is_empty() || rest.starts_with('[') => {
// note: this does not actually emit valid Solidity because there are no inline
// tuple types (`(T, U, V, ...)`), but it's valid for `sol!`.
out.push_str("(");
// tuple types `(T, U, V, ...)`, but it's valid for `sol!`.
out.push('(');
for (i, component) in components.iter().enumerate() {
if i > 0 {
out.push_str(", ");
Expand Down

0 comments on commit 7a55e0a

Please sign in to comment.