tweaking @decorator syntax

John Roth newsgroups at jhrothjr.com
Fri Aug 6 15:21:17 CEST 2004


"John Marshall" <John.Marshall at ec.gc.ca> wrote in message
news:mailman.1195.1091715452.5135.python-list at python.org...
> On Thu, 2004-08-05 at 08:41, Sandy Norton wrote:
> > On 4 Aug 2004, Christopher T King wrote:
>
> With the current choice and the list of alternatives you gave,
> two things struck me about the location of the decorators
> in the current choice:


>     2) Can decorators easily be extended to apply to class
>        and module?

Since I've never gotten my head around metaclasses,
I suspect that I'd find the ability to simply declare a
function that would "fix" a class at class definition time
to be a real help.

On the other hand, I'm not entirely sure what
you'd use that ability for on the module level.

John Roth





More information about the Python-list mailing list