Python 2.2 properties
peter at engcorp.com
Wed Jan 16 00:06:37 EST 2002
Mark McEahern wrote:
> Given these suggestions, I'd probably suggest something like this:
> """property only works with new-style classes. There are two ways to write
> a new style class:
> 1. Derive your class directly from object.
> 2. Derive from a class that derives from object (e.g., list)."""
> Or you could collapse 2 into 1:
> Derive your class either directly or indirectly from object.
To a programmer who understands object-oriented programming,
I would think saying both is redundant. Subclasses are
subclasses, and implement or override the features of their
ancestors, no matter how far descended.
More information about the Python-list