On Dé Céadaoin, Ean 26, 2005, at 13:45 America/Chicago, Steven Bethard wrote:

Note that:
    @deco
    def func(...):
        ...
is basically just syntactic sugar for:
    def func(...):
        ...
    func = deco(func)

Oh, I learned something new today :-) Nice thing to know, these descriptors.


Note that b.size and d.size are only calculated once each, and if d.size is never accessed, you'll never incur the costs of calculating it.

That's exactly what I need. It works fine for Python 2.2 and 2.3. So, I'll try to implement that into my package.


Thanks a bunch for your help,

Christian

--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to