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

Implement Euclid division and remainder #245

Merged
merged 6 commits into from Aug 22, 2023
Merged

Implement Euclid division and remainder #245

merged 6 commits into from Aug 22, 2023

Conversation

jaybosamiya
Copy link
Contributor

Now that a common trait for this has been sorted out (rust-num/num-traits#159 implemented and merged in rust-num/num-traits#195), we can now close #146 by implementing the trait for BigInts. This commit does just that.

Copy link
Member

@cuviper cuviper left a comment

Choose a reason for hiding this comment

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

Hi, and sorry for review silence.

For completeness, can you also add the trivial implementations for BigUint?

src/bigint/division.rs Outdated Show resolved Hide resolved
@jaybosamiya
Copy link
Contributor Author

Thanks for the review! I've added commits based on the above requested changes, and the branch is now ready for another review.

@cuviper
Copy link
Member

cuviper commented Aug 22, 2023

I rebased this and added a couple compat fixes. Otherwise, looks good, thanks!

bors r+

bors bot added a commit that referenced this pull request Aug 22, 2023
245: Implement Euclid division and remainder r=cuviper a=jaybosamiya

Now that a common trait for this has been sorted out (rust-num/num-traits#159 implemented and merged in rust-num/num-traits#195), we can now close #146 by implementing the trait for `BigInt`s. This commit does just that.

Co-authored-by: Jay Bosamiya <jaybosamiya@gmail.com>
Co-authored-by: Josh Stone <cuviper@gmail.com>
@bors
Copy link
Contributor

bors bot commented Aug 22, 2023

Build failed:

@cuviper
Copy link
Member

cuviper commented Aug 22, 2023

bors retry

@bors
Copy link
Contributor

bors bot commented Aug 22, 2023

Build succeeded!

The publicly hosted instance of bors-ng is deprecated and will go away soon.

If you want to self-host your own instance, instructions are here.
For more help, visit the forum.

If you want to switch to GitHub's built-in merge queue, visit their help page.

@bors bors bot merged commit 27e4acf into rust-num:master Aug 22, 2023
4 checks passed
@jaybosamiya
Copy link
Contributor Author

Thanks for rebasing and merging!

@jaybosamiya jaybosamiya deleted the euclid-div-mod branch August 23, 2023 20:42
jaybosamiya added a commit to verus-lang/verus that referenced this pull request Aug 23, 2023
Now that rust-num/num-bigint#245 has been
merged, by updating the version of num-bigint used in Verus, we get to
remove our custom implementation of these two functions.
jaybosamiya added a commit to verus-lang/verus that referenced this pull request Aug 25, 2023
Now that rust-num/num-bigint#245 has been
merged, by updating the version of num-bigint used in Verus, we get to
remove our custom implementation of these two functions.
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.

Implement Euclidean division and modulo
2 participants