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 Add, Sub, CheckedAdd, CheckedSub for Uints #62

Open
4 tasks
ValarDragon opened this issue Apr 29, 2021 · 0 comments
Open
4 tasks

Implement Add, Sub, CheckedAdd, CheckedSub for Uints #62

ValarDragon opened this issue Apr 29, 2021 · 0 comments
Labels
D-easy Difficulty: easy T-feature Type: new features

Comments

@ValarDragon
Copy link
Member

Summary

We should add implementations of Add, Sub, CheckedSub and CheckedAdd for Uints. These are common functions one needs when working with Uints. Currently there only exists AddMany

CheckedAdd and CheckedSub should be unsatisfiable if there is an overflow. I think the simplest checked arithmetic implementation would be to just compute the final carry bit and ensure its 0

(The checked and non-checked methods can be implemented in separate PRs!)


For Admin Use

  • Not duplicate issue
  • Appropriate labels applied
  • Appropriate contributors tagged
  • Contributor assigned/self-assigned
@ValarDragon ValarDragon added T-feature Type: new features D-easy Difficulty: easy labels Apr 29, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
D-easy Difficulty: easy T-feature Type: new features
Projects
None yet
Development

No branches or pull requests

1 participant