We've been programming in Python for about a year. Initially we had a
lot of tests of the form
if x == None:
do_something()
but then someone thought that we should really change these to
if x is None:
do_something()
However. if you run pychecker on these two snippets of code, it
complains about the second, and not the first:
x.py:6: Using is None, may not always work
So the question is, which one should we really be using?
If it is the second, how do I get pychecker to shut up?
I've hunted around in the documentation, and if there is a clear
discussion about this issue, I must have missed it.
Cheers
Duncan
_______________________________________________
Tutor maillist - [email protected]
http://mail.python.org/mailman/listinfo/tutor