[Python-Dev] method decorators (PEP 318)

Skip Montanaro skip at pobox.com
Mon Mar 29 07:22:51 EST 2004


    >> I find the mark-up in your example about the worst possible mark-up;
    >> in practice, these things can get quite voluminous

    Greg> Something about the idea of functions having voluminous amounts of
    Greg> metadata disturbs me, especially for small functions. I don't want
    Greg> to have to wade through a dozen lines of metadata to get to a few
    Greg> lines of actual code that tells me what the function does.

Indeed.  If you're tempted to add voluminous amounts of metadata to a
function perhaps you should write a class instead, especially if you're
tempted to use *any* of that data at runtime.

Skip



More information about the Python-Dev mailing list