[Tutor] Decorators

Alan Gauld alan.gauld at freenet.co.uk
Tue Apr 11 09:36:42 CEST 2006


> My problem, and this is after reading PEP 318 and other items found when I
> "Googled" for decorators, is that I can't figure out the practical use for

There is no practical use for decorators IMHO
They are syntactic sugar added to the language to make some things
that were already possible a little tidier looking (things like class/static
 methods etc)

I don;t think there is anything that you need decorators to achieve that
you can'tdo without them. In that respect they are like python's support
for lambdas - nice to have but not essential to the language.

Others may feel differently! :-)

Alan G.



More information about the Tutor mailing list