-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
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
mod1 / rem1 documentation is inconsistent #8108
Labels
docs
This change adds or pertains to documentation
Comments
#5570 "mod1(x,y) doesn't work at all for unsigned x,y when x>y. Moreover fld1(x,y) gives rather less useful results for signed x<=0 and incorrect results for unsigned x=0." |
Merged
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The documentation for mod1(x,m) and rem1(x,m) is inconsistent for the case where m is negative: The interval (0,m] does not make sense in this case.
Also, given the implementation of rem1, it seems that the numerator x is assumed to be positive? For example, rem1(0,10) returns 0, and negative x lead to negative results.
The text was updated successfully, but these errors were encountered: