[Python-Dev] Questions about '@' in pep 318 (original) (raw)

Roman Suzi rnd at onego.ru
Fri Aug 6 13:44:54 CEST 2004


Hello,

I think @ before def are unacceptable because they aren't too Pythonic and thus break style and aestetics of Python. If we absolutely need those decorators, I propose to use existing construct which has some resemblance with other places of Python:

def func(x, y, z) % decorator: ...

and

def func(x, y, z) % (decorator1, decorator2, ...): ...

this has a meaning of "applying" decorators to the function (method). And it has minimal impact on readability.

Sincerely yours, Roman A.Suzi



More information about the Python-Dev mailing list