[Python-ideas] Suggestion: Extend integers to include iNaN

Serhiy Storchaka storchaka at gmail.com
Sat Sep 29 03:24:44 EDT 2018

29.09.18 09:31, Steve Barnes пише:
> I think that it should be relatively simple to extend the Python integer
> class to have a NaN flag, possibly by having a bit length of 0, and have
> it follow the same rules for the handling of floating point NaN, i.e.
> any mathematical operation on an iNaN returns an iNaN and any comparison
> with one returns False.

How does it differ from float('nan')?

More information about the Python-ideas mailing list