Generator expressions are due in Python 2.4, and are discussed in the current draft of Andrew Kuchling's What's New In Python 2.4 (work in progress). They provide a fairly amenable syntax for expressing stream processing idioms (lazily-evaluated operations on lists).
I find it fascinating that Python is so often pulled in the direction of functional programming (especially Haskell), in spite of GvR's own inclinations (dislike of lambda, etc). Python metaprogramming is another area that's seen a lot of interest, in spite of the fact that using metaclasses, __new__, descriptors and all the rest of the machinery takes you further and further away from Python's original "Pythonic" simplicity.
Decorator syntax has been the topic of much debate. I think the only thing everyone agrees on is that the current workarounds are syntactically ugly and obtuse:
class Foo(object):
def aMethod(cls, *args):
pass
aMethod = classmethod(aMethod)
def anotherMethod(*args):
pass
anotherMethod = staticMethod(anotherMethod)
It will be interesting to see how this is resolved. Syntax may not be of paramount importance, but syntax design is still design (and it's still hard...)
|