-
Notifications
You must be signed in to change notification settings - Fork 56
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
refactor: Refactor namespace allocations using ns!
macro
#1132
Conversation
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 but it would be better to wait for more reviewers
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.
These look good to me, it's very nice to see gadget calls fit in a single line again.
Is there anything we should be careful with regard to calling macros in macros though?
Recursion isn't allowed, but otherwise that's a common pattern, and how |
- This codemod was generated by the command ``` rustby '&mut :[cs].namespace(|| :[e])' 'ns!(:[cs], :[e])' ``` where rustby is an alias for `comby -matcher .rs -extensions .rs -in-place -jobs 10 -exclude-dir "target,.github" -stats -timeout 15 $@` - Comprehensive refactoring done across multiple modules, including `coprocessor/mod.rs`, `coroutine/memoset/env.rs`, `circuit/circuit_frame.rs`, `circuit/gadgets/pointer.rs`, and many more. - Switched from `.namespace()` function to the `ns!` macro throughout the code to improve simplicity and readability.
459ddd0
7faec24
to
459ddd0
Compare
where rustby is an alias for
comby -matcher .rs -extensions .rs -in-place -jobs 10 -exclude-dir "target,.github" -stats -timeout 15 $@
coprocessor/mod.rs
,coroutine/memoset/env.rs
,circuit/circuit_frame.rs
,circuit/gadgets/pointer.rs
, and many more..namespace()
function to thens!
macro throughout the code to improve simplicity and readability.