]> granicus.if.org Git - python/commitdiff
I should add that the previous checkin also added a slight
authorGuido van Rossum <guido@python.org>
Thu, 16 Aug 2001 15:42:49 +0000 (15:42 +0000)
committerGuido van Rossum <guido@python.org>
Thu, 16 Aug 2001 15:42:49 +0000 (15:42 +0000)
optimization for dynamic classes.  If __getattr__ is not found as an
attribute on the type, slot_tp_getattro replaces itself with
PyObject_GenericGetAttr.  This means you can't add a __getattr__
method to a class after the fact -- but you can still *change* a
__getattr__ method into a different one.

(A similar restriction exists for classic classes.)


No differences found