[Python-Dev] pep 318, Decorators for Functions, Methods and Classes (original) (raw)

Skip Montanaro skip at pobox.com
Tue Aug 10 17:25:53 CEST 2004


(still catching up...)

Simon> I just wanted to say that I believe it should be allowed to
Simon> decorate classes. There's not reason enough (reading the thread
Simon> linked to by the PEP) to limit decorators this way. Like said
Simon> several times in that thread, metaclasses are harder (to write
Simon> and to understand) than decorators.

While it might be perceived as a limitation there's nothing preventing its addition in a later version if warranted. I believe most/all the various proposals on the PythonDecorators wiki, not just the pie syntax, could be easily adapted to class decoration.

Skip



More information about the Python-Dev mailing list