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: add parsing support for JSON items #329

Merged
merged 9 commits into from
Oct 4, 2023
Merged

feat: add parsing support for JSON items #329

merged 9 commits into from
Oct 4, 2023

Conversation

DaniPopes
Copy link
Member

Add FromStr and parse associated functions to json-abi items and params.

Supersedes #310
Closes #291

crates/json-abi/src/item.rs Outdated Show resolved Hide resolved
crates/sol-type-parser/src/parameter.rs Outdated Show resolved Hide resolved
Copy link
Member

@gakonst gakonst left a comment

Choose a reason for hiding this comment

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

supportive

crates/sol-type-parser/src/parameter.rs Outdated Show resolved Hide resolved
crates/sol-type-parser/src/lib.rs Show resolved Hide resolved
crates/sol-type-parser/src/error.rs Show resolved Hide resolved
crates/json-abi/src/item.rs Outdated Show resolved Hide resolved
crates/json-abi/src/item.rs Outdated Show resolved Hide resolved
crates/json-abi/src/item.rs Show resolved Hide resolved
crates/json-abi/src/item.rs Outdated Show resolved Hide resolved
crates/json-abi/src/item.rs Outdated Show resolved Hide resolved
Copy link
Member

@prestwich prestwich left a comment

Choose a reason for hiding this comment

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

approving for when you feel it's ready @DaniPopes

@DaniPopes
Copy link
Member Author

Small thing about this is that all parse functions use the same parser, so they will accept and ignore stuff like "indexed" and state mutability instead of returning an error, which I don't think is that bad

crates/json-abi/src/abi.rs Show resolved Hide resolved
crates/json-abi/src/item.rs Outdated Show resolved Hide resolved
@DaniPopes DaniPopes merged commit c2945a3 into main Oct 4, 2023
20 checks passed
@DaniPopes DaniPopes deleted the dani/hrparser branch October 4, 2023 22:09
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.

[Feature] Implement human-readable ABI parser
3 participants