Raymond Hettinger wrote:
[Peter Otten]

Do you see any chance that list comprehensions will be redefined as an
alternative spelling for list(<generator expression>)?

Not likely. It is possible that the latter spelling would make it possible for Py3.0. eliminate list comps entirely. However, they are very popular and practical, so my bet is that they will live on.

I suspect you're right, but I certainly wouldn't complain if list comps disappeared. TOOWTDI and all, and I often find myself alternating between the two when I can't decide which one seems more Pythonic. (These days I generally write a listcomp, but I wouldn't put any money on my code being entirely consistent about this...)


STeVe
--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to