Re: [Python-Dev] Decimal & lt; -& gt; float comparisons in py3k.

2010-03-19 Thread Greg Ewing
Glenn Linderman wrote: In order to do implicit comparisons, one must do an implicit coercion. Hence the PEP actually already prohibits implicit comparisons, as well as implicit arithmetic. Not necessarily -- you could compare them as though they had both been converted to the equivalent rati

Re: [Python-Dev] Decimal & lt; -& gt; float comparisons in py3k.

2010-03-19 Thread Raymond Hettinger
On Mar 19, 2010, at 11:42 AM, Glenn Linderman wrote: >> > > The whole point of providing Decimal is for applications for which float is > inappropriate. I didn't think I needed to reproduce PEP 327 in my email. > > So when a coder choose to use Decimal, it is because float is inappropriate.

Re: [Python-Dev] Decimal & lt; -& gt; float comparisons in py3k.

2010-03-19 Thread Glenn Linderman
On 3/19/2010 4:50 AM, Antoine Pitrou wrote: Glenn Linderman nevcal.com> writes: On the other hand, if the default behavior is to do an implicit conversion, I don't know of any way that that could be turned into an exception for those coders that don't want or don't like the particular type

Re: [Python-Dev] Decimal & lt; -& gt; float comparisons in py3k.

2010-03-19 Thread Raymond Hettinger
On Mar 19, 2010, at 4:50 AM, Antoine Pitrou wrote: > Glenn Linderman nevcal.com> writes: >> >> On the other hand, if the default behavior is to do an implicit >> conversion, I don't know of any way that that could be turned into an >> exception for those coders that don't want or don't like t

Re: [Python-Dev] Decimal & lt; -& gt; float comparisons in py3k.

2010-03-19 Thread Antoine Pitrou
Glenn Linderman nevcal.com> writes: > > On the other hand, if the default behavior is to do an implicit > conversion, I don't know of any way that that could be turned into an > exception for those coders that don't want or don't like the particular > type of implicit conversion chosen. You s