Skip to content
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

feat(json-abi): support legacy JSON ABIs #596

Merged
merged 1 commit into from
Apr 9, 2024
Merged

Conversation

DaniPopes
Copy link
Member

Supersedes #350
Closes foundry-rs/foundry#7593

Copy link
Member

@mattsse mattsse left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

Comment on lines +65 to +66
/// Usage: `#[serde(default, flatten, with = "serde_state_mutability_compat")]` on a
/// [`StateMutability`] struct field.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

TIL this is possible

Copy link
Member Author

@DaniPopes DaniPopes Apr 9, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same, I was praying this would work, and it did 🙏

Initially I tried with only the deserialize function, but that would make #[serde(flatten)] apply to the StateMutability enum alone, which throws an error at runtime

@DaniPopes DaniPopes merged commit 2723294 into main Apr 9, 2024
21 checks passed
@DaniPopes DaniPopes deleted the dani/legacy-json branch April 9, 2024 00:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

"cast interface" does not output payable functions as payable
2 participants