None inconsistent

mjhand at concentric.net mjhand at concentric.net
Thu Jun 10 15:52:20 EDT 1999


Pardon the repetition (if this is repetitive).  I have posted
this message three times but have yet to see it appear on the
newsgroup.

In 1.5.1, "None" was "less" than all numbers:
>>> 0 < None
0
>>> sys.maxint > None
1

In 1.5.2, "None" became "greater" than all numbers:
>>> 0 < None
1
>>> sys.maxint > None
0

I have three questions about this:
(1) Was this change made intentionally?  (I hope so.)
(2) Can we count on it staying this way forever?  (I hope so.)
(3) When will the starship be updated to use 1.5.2 by default?
    (/usr/bin/python == 1.5.1, /usr/local/bin/python == 1.5.2b2)

I absolutely LOVE that "None" is accepted as a valid argument in
min(), max(), and cmp(), but I would like it to behave consistently.
The 1.5.2 way is best for my code.  Please tell me it will stay
that way forever.

Thanks,
Manus


Sent via Deja.com http://www.deja.com/
Share what you know. Learn what you don't.




More information about the Python-list mailing list