-
Notifications
You must be signed in to change notification settings - Fork 503
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
Add PrimeFieldBits support to Scalar #579
Merged
Merged
Changes from 1 commit
Commits
Show all changes
11 commits
Select commit
Hold shift + click to select a range
8b63cb2
Add PrimeFieldBits support to Scalar
kayabaNerve 22c0d80
Sane char_le_bits
kayabaNerve 6fe7d8b
Add bits feature
kayabaNerve dc276b1
Correct bits feature flagging
kayabaNerve 5b6d4de
FieldBits, fmt
kayabaNerve 9f8aec1
fmt, again, due to my fault
kayabaNerve 268da71
Merge branch 'main' into patch-2
kayabaNerve 5abdf53
group-bits feature flag
kayabaNerve f5c321b
Update CHANGELOG.md
kayabaNerve 4dbf578
Merge branch 'main' into patch-2
rozbb 1d57d14
Use BASEPOINT_ORDER_PRIVATE instead of BASEPOINT_ORDER
rozbb File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
I think this should work but haven't tested it
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.
I'll test it now, thanks.
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.
That's a Scalar, not a byte array. Doesn't that break safety to have an unreduced Scalar in system? Especially now that Scalar addition assumes only unreduced Scalars exist? I'd guess it doesn't in practice, as it won't have any shouldn't never be set bits set, yet still sounds like something which should be a
[u8; 32]
.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.
to_bytes().into() works, will push that.
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.
Yeah, seems a bit odd to have it in the public API if it's unreduced /cc @rozbb
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.
BASEPOINT_ORDER
will be marked deprecated from 4.1.1 - this will beBASEPOINT_ORDER_PRIVATE
as pub(crate)BASEPOINT_ORDER
from pub API consts #581