Benjamin Peterson <benja...@python.org> added the comment:

On Tue, Feb 17, 2009 at 1:27 PM, Antoine Pitrou <rep...@bugs.python.org> wrote:
>
> Antoine Pitrou <pit...@free.fr> added the comment:
>
> If iterators don't want their boolean value to be messed up, couldn't
> they simply use __bool__ for that?

Since there is no base iterator class, that would complicate the API
and lead to subtle bugs. Personally, I don't think any iterators
should supported len() at all.

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

Reply via email to