[issue11406] There is no os.listdir() equivalent returning generator instead of list
Марк Коренберг
report at bugs.python.org
Wed Mar 9 06:43:13 CET 2011
Марк Коренберг <socketpair at gmail.com> added the comment:
> -1 on going back through blah/xblah all over again.
Originally, I want return value of listdir to be changed from list to generator. But next, I thought about compatibility. It will break some code. For example, SimpleHTTPServer:
list = os.listdir(path)
list.sort(key=lambda a: a.lower())
will not work.
----------
_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue11406>
_______________________________________
More information about the Python-bugs-list
mailing list