Author jyasskin
Recipients facundobatista, gvanrossum, jyasskin, mark.dickinson, ncoghlan, rhettinger
Date 2008-02-18.22:51:04
SpamBayes Score 0.164307
Marked as misclassified No
Message-id <1203375066.09.0.564373913782.issue1682@psf.upfronthosting.co.za>
In-reply-to
Content
1) No worries. Even without inlining the common case of __add__, etc.,
Fraction is now faster than Decimal for smallish fractions
[sum(Fraction(1, i) for i in range(1, 100))], and for large ones
[sum(Fraction(1, i) for i in range(1, 1000))] gcd takes so much of the
time that I can't see the effects of any of the optimizations I've made.
Since I wasn't thinking of this as a high-performance class, I'm taking
that as a sign to stop optimizing, but gcd is definitely the function to
tackle if anyone wants to keep going.

2) I haven't been following __format__, but adding it to Rational sounds
fine to me.
History
Date User Action Args
2008-02-18 22:51:06jyasskinsetspambayes_score: 0.164307 -> 0.164307
recipients: + jyasskin, gvanrossum, rhettinger, facundobatista, mark.dickinson, ncoghlan
2008-02-18 22:51:06jyasskinsetspambayes_score: 0.164307 -> 0.164307
messageid: <1203375066.09.0.564373913782.issue1682@psf.upfronthosting.co.za>
2008-02-18 22:51:05jyasskinlinkissue1682 messages
2008-02-18 22:51:04jyasskincreate