Marc 'BlackJack' Rintsch wrote:
> K.S.Sreeram wrote:
>> The very fact that you can put a loop inside __metaclass__ may be reason
>> enough for a one-off metaclass.
> 
> Ah, it's not the loop but the access to the `dict`!  You can write loops
> at class level too but I haven't found a way to access `X`s `__dict__`
> because `X` does not exist at this point.

You're right. I guess i wasn't clear in my previous post, but I was
referring to 'the ability to process the dict (say, using loops)'

> BTW, if that's what gangesmaster is after then it seem to work already. 
> Put ``(object)`` after ``X`` and return something, say 'a' and 'b', in the
> getters and the example prints 'a' and 'b'.

btw, the example seems to work even with old-style classes.

Regards
Sreeram

Attachment: signature.asc
Description: OpenPGP digital signature

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

Reply via email to