[Python-Dev] def ... decorate (original) (raw)

Charles Cazabon python at discworld.dyndns.org
Fri Aug 13 20:27:51 CEST 2004


Raymond Hettinger <python at rcn.com> wrote:

> I've kept my nose out of the decorator discussion, but I thought I would > give my opinion on this one... [...] Advantages:

* Won't delude people into thinking they can understand a python program just by reading it.

:)

I've lost track of all the decorator proposals. Anyone proposed something like this?

def f { 'accepts' : (type1, type2), 'returns' : (int, str)} funcname (args):

? The decorator dictionary could span multiple lines, of course.

Charles


Charles Cazabon <python at discworld.dyndns.org> GPL'ed software available at: http://www.qcc.ca/~charlesc/software/



More information about the Python-Dev mailing list