This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author terry.reedy
Recipients terry.reedy
Date 2009-07-09.21:21:28
SpamBayes Score 6.3993872e-09
Marked as misclassified No
Message-id <1247174489.94.0.772158623478.issue6453@psf.upfronthosting.co.za>
In-reply-to
Content
>>> cc=c()
>>> bool(cc)
Traceback (most recent call last):
  File "<pyshell#5>", line 1, in <module>
    bool(cc)
TypeError: __bool__ should return bool or int, returned int

This is slightly jarring.
Adding ' 0 or 1' after 'or int' would be nice (and trivial).
Adding str(val) at the end after type(val) would be even nicer.
History
Date User Action Args
2009-07-09 21:21:30terry.reedysetrecipients: + terry.reedy
2009-07-09 21:21:29terry.reedysetmessageid: <1247174489.94.0.772158623478.issue6453@psf.upfronthosting.co.za>
2009-07-09 21:21:28terry.reedylinkissue6453 messages
2009-07-09 21:21:28terry.reedycreate