NaN comparisons - Call For Anecdotes

Marko Rauhamaa marko at pacujo.net
Tue Jul 8 12:16:53 EDT 2014


Chris Angelico <rosuav at gmail.com>:

> Why *should* all NaNs be equal to each other?

I appreciate why you can't say NaN is equal to NaN. However, shouldn't
the very comparison attempt trigger an arithmetic exception? After all,
so does a division by zero.


Marko



More information about the Python-list mailing list