[Python-Dev] Call for defense of @decorators (original) (raw)
Greg Ewing greg at cosc.canterbury.ac.nz
Fri Aug 6 04:24:02 CEST 2004
- Previous message: [Python-Dev] Call for defense of @decorators
- Next message: [Python-Dev] Call for defense of @decorators
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Ronald Oussoren <ronaldoussoren at mac.com>:
And how would that solve this: <http://www.eby-sarna.com/pipermail/peak/2004-July/001598.html>
FWIW, in decorator-plus-function-attributes style, this would be
def do_something(x,y) [generic]: @when = "x in int and y in str" # body here will be executed when 'x' # is an integer and 'y' is a string
Greg Ewing, Computer Science Dept, +--------------------------------------+ University of Canterbury, | A citizen of NewZealandCorp, a | Christchurch, New Zealand | wholly-owned subsidiary of USA Inc. | greg at cosc.canterbury.ac.nz +--------------------------------------+
- Previous message: [Python-Dev] Call for defense of @decorators
- Next message: [Python-Dev] Call for defense of @decorators
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]