What's the value of "None" between 2.1.1 and 1.5.2

Skip Montanaro skip at pobox.com
Fri Nov 30 04:23:42 CET 2001

    Ozone> I have written a simulation in python 1.5.2....  It used to work
    Ozone> fine.

    Ozone> When I logged on a new machine which has Python 2.1.1 installed,
    Ozone> my simulation has gone wild.  Later on, I figured that out one
    Ozone> weird thing about the value of "None":

You were relying on undocumented behavior.  There is no obvious ordering
between integers and None.

    Ozone> I don't really want to fix this type of bug again whenever Python
    Ozone> upgrades....

Then fix your program so it doesn't rely on this.  You'll only have to fix
it once.  ;-)

Skip Montanaro (skip at pobox.com - http://www.mojam.com/)

More information about the Python-list mailing list