J2 proposal: keyword

Oliver Fromme olli at haluter.fromme.com
Mon Aug 23 18:47:42 CEST 2004


Robert Brewer <fumanchu at amor.org> wrote:
 > III. Choosing a keyword
 > [...]
 > -Candidates for keywords have fallen into two or three camps, and
 > emphasize different aspects of decorators: 
 > 
 > -Declarative: declare, predef, moddef 
 > -Transformative: transform, wrap, modify, mutate 
 > -Attributive/Annotative: amend, using, having 
 > -Directive: pragma, signify 
 > -Associative: helper, qualify, qual, meta 
 > -Cross-cutting: imbue, endow, bestow, embellish, extend, accum, glom,
 > confer
 > -Prepositions/Adverbs: using, through, per, via, by

Aren't decorators just functions that are applied to the
function definition?  Then how about "apply"?  It's short
(for those lazy typers), and it expresses exactly what
happens.


apply:
    staticmethod
    memoize
def foo (int):
    pass


Best regards
   Oliver

-- 
Oliver Fromme, Konrad-Celtis-Str. 72, 81369 Munich, Germany

``All that we see or seem is just a dream within a dream.''
(E. A. Poe)



More information about the Python-list mailing list