Sept. 10, 2004
1:59 p.m.
Phillip J. Eby wrote:
I like the PEP with 'and' and 'or', but isn't the 'not' special method essentially the inverse of __nonzero__?
There isn't such a method currently.
Did you mean to say that there is currently no method named __nonzero__? This is not true:
class X: ... def __nonzero__(self): ... print "Called" ... return 13 ... not X() Called False
Regards, Martin