Tim Peters <t...@python.org> added the comment:

Terry, we could do that, but the opposition here isn't strong, and is pretty 
baffling anyway ;-) : the suggested changes are utterly ordinary for 
implementations of rationals, require very little code, are not delicate, and 
are actually straightforward to see are correct (although unfamiliarity can be 
an initial barrier - e.g., if you don't already know that after

     g = gcd(a, b)
     a1 = a // g
     b1 = b // g

it's necessarily true that a1 and b1 are coprime, a key reason for way the 
transformation is correct will be lost on you - but it's also very easy to 
prove that claim once you're told that it is a key here). The OP is right that 
"we" (at least Mark, and Raymond, and I) have routinely checked in far subtler 
optimizations in various areas.

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue43420>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to