Variable inheritance

Roman Suzi rnd at onego.ru
Wed May 23 07:22:03 CEST 2001


On Tue, 22 May 2001, Alex Martelli wrote:

> "Roman Suzi" <rnd at onego.ru> wrote in message
> news:mailman.990533131.26026.python-list at python.org...
> > On 22 May 2001, Paul Foley wrote:
> >
> > > On Tue, 22 May 2001 11:58:34 +0400 (MSD), Roman Suzi wrote:
> > >
> > > > The badness of multiple inheritance is not bounded with the underlying
> > > > language. It's bad design decision, because it artificially combines
> two
> > > > classes, which very rarely reflect real situation. (I can't even give
> > >
> > > Virtually every creature on earth more sophisticated than a bacterium
> > > inherits from two parents :-)
> >
> > But it never happens between CLASSES of creatures ;-)
> 
> It happens all the time -- because classification is basically
> never a taxonomy, in reality.  *Classes of interest are NOT
> mutually exclusive* is the NORM.  Which is one typical failing
> of "the IS of identity", as it SEEMS from "A is B" that there
> follows "A is-not other-than-B"... but it doesn't:-).
> 
> "Flying Creature" vs "Swimming Creature" vs "Walking Creature"...
> many creatures have multiple ways of locomotion.  Air-Breather
> vs Water-Breather... ever heard of amphibians?-)

Yes! 

But Python allows to add properties independently of 
inheritance. Some time ago I posted an example for 
constructing above mentioned creatures without 
any inheritance.

Properties could be used on their own, without 
complications of inheritance! (which sometimes
inherits more than needed).

> "Mammal" vs "Insect" vs "Bird" &c *AND* "Male" vs "Female".
> What creature _doesn't_ "inherit" one from column A _and_
> one from column B in this case?-)  Why, most PLANTS, which
> are BOTH male and female -- and several animals have that
> interesting trait to, often for different stages of life,
> but not always.
> 
> Alex
> 
> 
> 

Sincerely yours, Roman A.Suzi
-- 
 - Petrozavodsk - Karelia - Russia - mailto:rnd at onego.ru -
 






More information about the Python-list mailing list