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
Use rich_to_bool_sgn instead of rich_to_bool when comparing outputs of mpz_cmp #29094
Comments
Branch pushed to git repo; I updated commit sha1. New commits:
|
Commit: |
Branch pushed to git repo; I updated commit sha1. This was a forced push. New commits:
|
comment:4
looks good. But why are there 2 changes ? |
comment:5
That second change is because the documentation says it returns |
comment:6
ok, you can set to positive as soon as the lights are green by the way, the related #28945 seems not to work with the latest beta. Maybe the same kind of issue ? |
Reviewer: Frédéric Chapoton |
comment:8
Doesn't seem like it, but I will have to investigate further. Thank you for doing the review. |
Changed branch from public/algebra/fix_comparisons_mpz_cmp-29094 to |
According to its documentation,
mpz_cmp
yields arbitrary positive/negative numbers, butrich_to_bool
assumes the input is in[-1, 0, 1]
. Thus it yields wrong results:CC: @mmasdeu @fchapoton
Component: algebra
Keywords: comparison
Author: Travis Scrimshaw
Branch/Commit:
501d5af
Reviewer: Frédéric Chapoton
Issue created by migration from https://trac.sagemath.org/ticket/29094
The text was updated successfully, but these errors were encountered: