making python 2.3 not complain about generator expressions?
ark at acm.org
Tue Jul 13 05:40:07 CEST 2004
"Dan Christensen" <jdc at uwo.ca> wrote in message
news:87iscs4m06.fsf at uwo.ca...
> I'd like to be able to do something like:
> if pythonversion >= 2.4:
> g = (x for x in [1,2,3])
> g = iter([1,2,3])
> But even though the first branch doesn't execute in python 2.3, the
> parser still complains.
if pythonversion >= 2.4:
import newcode as code
import oldcode as code
More information about the Python-list