-
Notifications
You must be signed in to change notification settings - Fork 723
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Nested Struct encoding example #1129
Conversation
Ignore the cast balance commit. It already got merged in another PR #1128. |
src/misc/struct-encoding.md
Outdated
"type": "function" | ||
} | ||
``` | ||
which reads: The function `f` takes 1 input of type tuple with three components: a string, a uint256, and another tuple representing the nested struct with components addr of type address and amount of type uint256. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can we add an example of what this looks like when invoked? otherwise lgtm
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can we add an example of what this looks like when invoked? otherwise lgtm
Like how? adding a transaction example having MyStruct
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
like how you would pass it to e.g. constructor args for forge create
, or for abi encoding with cast abi-encode
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
like how you would pass it to e.g. constructor args for
forge create
, or for abi encoding withcast abi-encode
added examples for both forge create
and cast abi-encode
, accidentally replied from my another acc on the above comment.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm, pending @onbjerg
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm, thank u !
Closes #1095