#19939: Fix EuclideanRings.ParentMethods._test_quo_rem to use `not r.is_zero()`
rather than `r!=0`
-------------------------------------+-------------------------------------
Reporter: nthiery | Owner:
Type: defect | Status: needs_review
Priority: major | Milestone: sage-7.1
Component: categories | Resolution:
Keywords: | Merged in:
Authors: Nicolas M. Thiéry | Reviewers: Samuel Lelièvre
Report Upstream: N/A | Work issues:
Branch: | Commit:
u/nthiery/fix_euclideanrings_parentmethods__test_quo_rem_to_use__not_r_is_zero____rather_than__r__0_|
2d11e11975a16a496f16c8f56151a3932b45ed71
Dependencies: #19937 | Stopgaps:
-------------------------------------+-------------------------------------
Comment (by jdemeyer):
Replying to [comment:5 nthiery]:
> I indered pondered about this. I went for using `r.is_zero()` for
> style consistency with the nearby zero tests. But I don't have a
> strong opinion, and I am fine switching to `if r`. In that case, maybe
> the nearby zero tests should be changed accordingly for
> consistency. What do you think?
I don't have a strong opinion. When choosing between different equivalent
options like this, I would choose depending on efficiency and you cannot
beat `if r` then. Feel free to change all zero tests like this.
--
Ticket URL: <http://trac.sagemath.org/ticket/19939#comment:6>
Sage <http://www.sagemath.org>
Sage: Creating a Viable Open Source Alternative to Magma, Maple, Mathematica,
and MATLAB
--
You received this message because you are subscribed to the Google Groups
"sage-trac" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/sage-trac.
For more options, visit https://groups.google.com/d/optout.