[Python-Dev] Re: Call for defense of @decorators (original) (raw)
"Martin v. Löwis" martin at v.loewis.de
Fri Aug 6 20:25:28 CEST 2004
- Previous message: [Python-Dev] Re: Call for defense of @decorators
- Next message: [Python-Dev] Re: Call for defense of @decorators
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Christian Tismer wrote:
the primary purpose of all the decorator syntax effort is to get the
foo = classmethod(foo) into the right place, not after but before the definition. Dunno if this was mentioned before, but why not simply do that? Move the statement right before the def and provide a way that this gets recognized correctly. No syntax change, just the convenience people asked for.
I don't think this can work. How precisely would you implement it? Python traditionally executes source code from top to bottom, except for loops.
Regards, Martin
- Previous message: [Python-Dev] Re: Call for defense of @decorators
- Next message: [Python-Dev] Re: Call for defense of @decorators
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]