This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author scoder
Recipients brg@gladman.plus.com, gladman, mark.dickinson, scoder, vstinner
Date 2014-09-24.11:41:03
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1411558863.94.0.757378602381.issue22477@psf.upfronthosting.co.za>
In-reply-to
Content
I suggest adding a new implementation instead of replacing the current function in the fractions module. As Mark noted, the current gcd() is more of a sideeffect of the fractions module, but there's no real need to change that. It works perfectly ok for a) the Fraction type and b) positive input values.

Even if there's no other module namespace for this functionality that is more suitable than fractions, it could still be added under a different name, say, absgcd() or whatever. Something that makes it clear(er) how negative input is handled. The mere name "gcd" isn't very telling on that front.
History
Date User Action Args
2014-09-24 11:41:04scodersetrecipients: + scoder, mark.dickinson, vstinner, gladman, brg@gladman.plus.com
2014-09-24 11:41:03scodersetmessageid: <1411558863.94.0.757378602381.issue22477@psf.upfronthosting.co.za>
2014-09-24 11:41:03scoderlinkissue22477 messages
2014-09-24 11:41:03scodercreate