Should proxy objects lie about their class name?
robin at reportlab.com
Tue Nov 27 18:13:57 CET 2007
Steven Bethard wrote:
> The Python 3 machinery allows *other* classes to lie about whether or
> not your object is an instance or subclass of them, without requiring
> them to set your __class__ or __bases__. So, for example, you can
> create a class ``Integer`` and make ``issubclass(int, Integer)`` true.
> For more information see:
That will allow me to magically create instances which claim to be instances of
working_class even though they're actually instances of reactionary_class thus
turning all my modules into instances of class_war :)
More information about the Python-list