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

Support yul ast #268

Merged
merged 19 commits into from
Sep 18, 2023
Merged

Support yul ast #268

merged 19 commits into from
Sep 18, 2023

Conversation

mouseless0x
Copy link
Contributor

@mouseless0x mouseless0x commented Sep 13, 2023

Motivation

Closes #237

Solution

Added Yul types as specified by the Solidity Language Grammar docs.

Notice

Parsing correctness has not been verified (not sure how to approach this).

Enforcement of syntax rules has not been accounted for, e.g., yul decimal numbers cannot start with leading zeros.

PR Checklist

  • Added Tests
  • Added Documentation
  • Breaking changes

Copy link
Member

@DaniPopes DaniPopes left a comment

Choose a reason for hiding this comment

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

First of all thank you so much for taking this on!

We have to get this right the first time to avoid major breaking changes in the future, I hope you don't mind the amount of comments 😸

crates/syn-solidity/src/yul/expr/fn_call.rs Outdated Show resolved Hide resolved
crates/syn-solidity/src/lib.rs Outdated Show resolved Hide resolved
crates/syn-solidity/src/yul/ident/mod.rs Show resolved Hide resolved
crates/syn-solidity/src/yul/ident/path.rs Outdated Show resolved Hide resolved
crates/syn-solidity/src/yul/lit/hex_num.rs Outdated Show resolved Hide resolved
crates/syn-solidity/src/yul/stmt/switch.rs Outdated Show resolved Hide resolved
crates/syn-solidity/src/yul/stmt/switch.rs Outdated Show resolved Hide resolved
crates/syn-solidity/src/yul/stmt/switch.rs Show resolved Hide resolved
crates/syn-solidity/src/yul/stmt/var_decl.rs Outdated Show resolved Hide resolved
crates/syn-solidity/src/yul/type/function.rs Outdated Show resolved Hide resolved
@mouseless0x
Copy link
Contributor Author

mouseless0x commented Sep 15, 2023

First of all thank you so much for taking this on!

We have to get this right the first time to avoid major breaking changes in the future, I hope you don't mind the amount of comments 😸

Thank you for the indepth review + comments, happy to implement the changes.

@mouseless0x
Copy link
Contributor Author

I believe all the changes have now been addressed.

Copy link
Member

@DaniPopes DaniPopes left a comment

Choose a reason for hiding this comment

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

Thanks!

@DaniPopes DaniPopes merged commit 2967dd9 into alloy-rs:main Sep 18, 2023
18 checks passed
@mouseless0x mouseless0x deleted the support-yul-ast branch September 19, 2023 03:15
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] Support yul AST
2 participants