Author mark.dickinson
Recipients alex, belopolsky, daniel.urban, mark.dickinson, rhettinger
Date 2011-05-14.18:50:32
SpamBayes Score 6.31042e-09
Marked as misclassified No
Message-id <1305399033.28.0.945166541094.issue11949@psf.upfronthosting.co.za>
In-reply-to
Content
It seems we're getting a bit off-topic for the issue title;  the discussion about cleaning up test_math (which I agree would be a good thing to do) should probably go into another issue.

On the issue itself, I'm -1 on making comparisons with float('nan') raise: I don't see that there's a real problem here that needs solving.  

Note that the current behaviour does *not* violate IEEE 754, since there's nothing anywhere in IEEE 754 that says that Python's < operation should raise for comparisons involving NaNs:  all that's said is that a conforming language should provide a number of comparison operations (without specifying how those operation should be spelt in the language in question), including both a < operation that's quiet (returning a false value for comparison with NaNs) and a < operation that signals on comparison with NaN.  There's nothing to indicate definitively which of these two operations '<' should bind to in a language.

It *is* true that C chooses to bind '<' to the signalling version, but that doesn't automatically mean that we should do the same in Python.
History
Date User Action Args
2011-05-14 18:50:33mark.dickinsonsetrecipients: + mark.dickinson, rhettinger, belopolsky, alex, daniel.urban
2011-05-14 18:50:33mark.dickinsonsetmessageid: <1305399033.28.0.945166541094.issue11949@psf.upfronthosting.co.za>
2011-05-14 18:50:32mark.dickinsonlinkissue11949 messages
2011-05-14 18:50:32mark.dickinsoncreate