[Python-Dev] Don't set local variable in a list comprehension or generator (original) (raw)

Greg Ewing greg.ewing at canterbury.ac.nz
Thu May 19 00:47:09 CEST 2011


Victor Stinner wrote:

squares = (x*x for x in range(10000))

What bytecode would you optimise that into?

-- Greg



More information about the Python-Dev mailing list