bpo-32968: Make modulo and floor division involving Fraction and float consistent with other operations (#5956)
Make mixed-type `%` and `//` operations involving `Fraction` and `float` objects behave like all other mixed-type arithmetic operations: first the `Fraction` object is converted to a `float`, then the `float` operation is performed as normal. This fixes some surprising corner cases, like `Fraction('1/3') % inf` giving a NaN.
Thanks Elias Zamaria for the patch. E
Elias Zamaria committed
393f1ff62e032f20adaed2613a9e2d2d6bcb1eb3
Parent: 74734f7
Committed by Mark Dickinson <mdickinson@enthought.com>
on 8/27/2018, 6:59:28 AM