-
Notifications
You must be signed in to change notification settings - Fork 29
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
Migrate Bytes to u128 internally #515
Conversation
Must defer consideration until November... |
Moving to December along w/ companion PR. |
I've added some significant macro clean up to what I originally did. |
5d7da97
to
881bac5
Compare
Rebased. |
CI is repeatedly failing due to #557 |
aca885e
to
0900f2c
Compare
This should also be ready due to rust-lang/rfcs#1504. |
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.
This looks generally good. I'm going over Mul, Div, and Rem very closely, as they are the most tricky for dimensionality and I've noted what looks like a problem w/ mul
macro.
Looks good. Moving to pending while I do review of stratisd part: stratis-storage/stratisd#2341. |
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.
Ok, looks ready! Please close this and open a PR for final review.
Add support in macros for u128 internal representation in unit structs. Move
Bytes
over to u128.There is a fair amount of added code and duplication in the macros as you cannot capture a type as a variable and then pattern match on it in a submacro so the types must be literals throughout the path travelled by the macro call stack. I would keep them all as variables if I didn't need to differentiate between
.serialize_u64()
and.serialize_u128()
in theserde_macro!()
body.