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 andrei.avk
Recipients Darragh Bailey, andrei.avk, anthonypjshaw, cjw296, lisroach, mariocj89, michael.foord, pconnell, r.david.murray, rbcollins, xtreak
Date 2021-08-28.03:05:05
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1630119905.25.0.227176314356.issue25597@roundup.psfhosted.org>
In-reply-to
Content
I went through dunder methods to check if any other operators or builtins work on objects without respective dunder methods:

 - del x works even though there is no object.__del__

 - operator.length_hint() => 0 when there is no object.__length_hint__

So in addition to __bool__, these dunder methods would have to be special cased.
History
Date User Action Args
2021-08-28 03:05:05andrei.avksetrecipients: + andrei.avk, rbcollins, cjw296, r.david.murray, michael.foord, pconnell, Darragh Bailey, lisroach, anthonypjshaw, mariocj89, xtreak
2021-08-28 03:05:05andrei.avksetmessageid: <1630119905.25.0.227176314356.issue25597@roundup.psfhosted.org>
2021-08-28 03:05:05andrei.avklinkissue25597 messages
2021-08-28 03:05:05andrei.avkcreate