-
Notifications
You must be signed in to change notification settings - Fork 13.2k
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
Tracking Issue for unchecked_div_rem
#136716
Comments
I won't be able to work on this for a little bit so if anyone wants, @rustbot label +E-easy +E-help-wanted |
@rustbot claim |
Those methods are a bit unusual in that the signed methods have more safety preconditions than the unsigned ones. So converting I think treating these differently would make sense and "consistency" is not a good argument. We do have some asymmetry between unsigned and signed types in other places too, for example |
@rustbot release-assignment |
@rustbot claim |
Do you think these should only exist on unsigned types then? Or not exist at all. |
@rustbot release-assignment |
@rustbot claim |
@the8472 @tgross35 Would it be a good idea to then implement 2 different versions of We could then tailor the failure condition being passed to I believe |
Feature gate:
#![feature(unchecked_div_rem)]
This is a tracking issue for unchecked versions of
/
and%
on integers. This is similar to existing methods likeunchecked_mul
.Public API
Steps / History
{integer}::unchecked_div
and{integer}::unchecked_rem
libs-team#526Unresolved Questions
unchecked_div_rem
#136716 (comment)Footnotes
https://std-dev-guide.rust-lang.org/feature-lifecycle/stabilization.html ↩
The text was updated successfully, but these errors were encountered: