Message3422

Author leosoto
Recipients leosoto
Date 2008-08-11.21:42:05
SpamBayes Score 0.052129526
Marked as misclassified No
Message-id <1218490927.5.0.926680117803.issue1102@psf.upfronthosting.co.za>
In-reply-to
Content
Currently, almost every lookup on a new-style instance (*Derived) does
in fact two lookups: first finds the '__getattribute__' slot in the type
mro, then the actual attribute lookup takes place. And, if
__getattribute__ raises AttributeError,  another mro lookup takes place,
this time for __getattr__.

This is somewhat solved on old-style instances (PyInstance), where the
__getattr__ slot is cached on PyClass. Although it has a problem: the
cache is not invalidated/refreshed when the __getattr__ slot is
dinamically changed.
History
Date User Action Args
2008-08-11 21:42:07leosotosetrecipients: + leosoto
2008-08-11 21:42:07leosotosetmessageid: <1218490927.5.0.926680117803.issue1102@psf.upfronthosting.co.za>
2008-08-11 21:42:07leosotolinkissue1102 messages
2008-08-11 21:42:06leosotocreate