Georg Brandl wrote:
> Sure, you could use ``iter(())`` or ``iter([])``, but for consistency's sake
> wouldn't it make sense for ``iter()`` to return an empty iterator, as
> ``str()``
> returns an empty string etc.?
>
> Georg
There is a difference.
>>> type(iter)
<type 'builtin_function_or_method'>
>>> type(str)
<type 'type'>
>>> type(int)
<type 'type'>
>>> type(list)
<type 'type'>
Cheers,
Ron
_______________________________________________
Python-Dev mailing list
[email protected]
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe:
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com