Hi,

PEP 289 says "the semantic definition of a list comprehension in
Python 3.0 will be equivalent to list(<generator expression>).

http://www.python.org/dev/peps/pep-0289/

I've just come across a bug reported by Peter Norvig, showing counterexamples.

http://bugs.python.org/issue14845

Very informative to understand the subtle differences between the
semantics of list comprehensions and generator expressions.

Anand
_______________________________________________
BangPypers mailing list
BangPypers@python.org
http://mail.python.org/mailman/listinfo/bangpypers

Reply via email to