In article <mailman.4061.1324811442.27778.python-l...@python.org>,
 Lie Ryan <lie.1...@gmail.com> wrote:

> Now, whether doing something like that is advisable or not, that's a 
> different question; however nothing in python states that you couldn't 
> have something that compare equal to None whether there is a bug or not 
> in the comparison method.

Just for fun, I tried playing around with subclassing NoneType and 
writing an __eq__ for my subclass.  Turns out, you can't do that:

Traceback (most recent call last):
  File "./none.py", line 5, in <module>
    class Nihil(NoneType):
TypeError: Error when calling the metaclass bases
    type 'NoneType' is not an acceptable base type
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to