| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
|
Most changes to Python require a NEWS entry. Please add it using the blurb_it web app or the blurb command-line tool. |
Sorry, something went wrong.
|
The following commit authors need to sign the Contributor License Agreement: |
Sorry, something went wrong.
|
Most changes to Python require a NEWS entry. Please add it using the blurb_it web app or the blurb command-line tool. |
Sorry, something went wrong.
|
The _normalize parameter is meant for internal use only, as an optimisation for creating objects when we know the numerator and denominator are already normalised. Fraction does not support unnormalised fractions. |
Sorry, something went wrong.
|
In fact, looks like it was removed entirely in #101780 |
Sorry, something went wrong.
| Back | FazBrowse Home | New Git URL |
If a fraction is created with the _normalize parameter set to false, it fill fail equality checks it should not.
For example before this fix: Fraction(4,2,_normalize=False) != 2.
This PR changes the equality check from just checking that the comparison int equals the numerator to checking that numerator/denominator is equal to the int.