[issue32968] Fraction modulo infinity should behave consistently with other numbers
Elias Zamaria
report at bugs.python.org
Thu Mar 1 17:00:13 EST 2018
Elias Zamaria <mikez302 at gmail.com> added the comment:
Mark, you said "if there's a test that's explicitly checking that `my_fraction // my_float` returns something of type `int`, then the behaviour is clearly intentional". I see exactly that. See https://github.com/python/cpython/blob/bf63e8d55fd2853df3bb99d66de7f428107aadb3/Lib/test/test_fractions.py#L404 In fact, when I said I made floordiv return a float, and "changed one test to make sure that it works", it was that test. So maybe that means we should be more cautious about changing the behavior of floordiv, if we decide to change it.
----------
_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue32968>
_______________________________________
More information about the Python-bugs-list
mailing list