Andrei Kulakov <andrei....@gmail.com> added the comment:

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.

----------
nosy: +andrei.avk

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue25597>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to