It seems the OP cannot even use Wikipedia. Between the links to the
page he cites
there is http://en.wikipedia.org/wiki/C3_linearization, which is the
way Multiple Inheritance is implemented in Python.
On Nov 7, 4:38 pm, Tim Golden <m...@timgolden .me.ukwrote:
Seriously, though, although Python does indeed support multiple inheritance,
I have the impression from comments over the years that it's used a lot less
than in other languages where it is more of a common idiom. Certainly in my
own (not negligible) use of Python, I've very rarely used it for anything
but the occasional mixin class.
>
I'll leave others to comment on whether this is indeed so and why
it might be :)
The reason is that in Python using composition is very easy, so there
is little need for MI
(which is a Good Thing).
In message
<90d2b348-73b4-446d-9673-3de62927d146@d4 2g2000prb.googl egroups.com>,
Michele Simionato wrote:
On Nov 7, 4:38Â pm, Tim Golden <m...@timgolden .me.ukwrote:
>
>Seriously, though, although Python does indeed support multiple
>inheritance, I have the impression from comments over the years that it's
>used a lot less than in other languages where it is more of a common
>idiom.
>
The reason is that in Python using composition is very easy, so there
is little need for MI
(which is a Good Thing).
Not to mention duck typing, which does away with the need for inheritance
altogether.
In message
<90d2b348-73b4-446d-9673-3de62927d146@d4 2g2000prb.googl egroups.com>,
Michele Simionato wrote:
>
>On Nov 7, 4:38 pm, Tim Golden <m...@timgolden .me.ukwrote:
>>
>>Seriously, though, although Python does indeed support multiple
>>inheritance , I have the impression from comments over the years that it's
>>used a lot less than in other languages where it is more of a common
>>idiom.
>The reason is that in Python using composition is very easy, so there
>is little need for MI
>(which is a Good Thing).
>
Not to mention duck typing, which does away with the need for inheritance
altogether.
That seems a somewhat extreme point of view.
regards
Steve
--
Steve Holden +1 571 484 6266 +1 800 494 3119
Holden Web LLC http://www.holdenweb.com/
>>On Nov 7, 4:38 pm, Tim Golden <m...@timgolden .me.ukwrote:
>>>
>>>Seriously, though, although Python does indeed support multiple
>>>inheritanc e, I have the impression from comments over the years that
>>>it's used a lot less than in other languages where it is more of a
>>>common idiom.
>>>
>>The reason is that in Python using composition is very easy, so there
>>is little need for MI (which is a Good Thing).
>>
>Not to mention duck typing, which does away with the need for inheritance
>altogether.
>
That seems a somewhat extreme point of view.
Hey, I didn't design the language, I just use it. :)
In message <mailman.3675.1 226101014.3487. python-list@python.org >, Steve
Holden wrote:
>
>Lawrence D'Oliveiro wrote:
>>
>>In message
>><90d2b348-73b4-446d-9673-3de62927d146@d4 2g2000prb.googl egroups.com>,
>>Michele Simionato wrote:
>>>
>>>On Nov 7, 4:38 pm, Tim Golden <m...@timgolden .me.ukwrote:
>>>>
>>>>Seriously , though, although Python does indeed support multiple
>>>>inheritance , I have the impression from comments over the years that
>>>>it's used a lot less than in other languages where it is more of a
>>>>common idiom.
>>>The reason is that in Python using composition is very easy, so there
>>>is little need for MI (which is a Good Thing).
>>Not to mention duck typing, which does away with the need for inheritance
>>altogether.
>That seems a somewhat extreme point of view.
>
Hey, I didn't design the language, I just use it. :)
I'm with Steve. Multiple inheritance is still a "good" thing, especially for
mixin-classes. wxPython, for instance, wouldn't be nearly so flexible without it.
In message <%lIRk.67026$vX 2.47488@bignews 6.bellsouth.net >, Larry Bates
wrote:
Lawrence D'Oliveiro wrote:
>
>In message <mailman.3675.1 226101014.3487. python-list@python.org >, Steve
>Holden wrote:
>>
>>Lawrence D'Oliveiro wrote:
>>>
>>>Not to mention duck typing, which does away with the need for
>>>inheritanc e altogether.
>>>
>>That seems a somewhat extreme point of view.
>>
>Hey, I didn't design the language, I just use it. :)
>
I'm with Steve. Multiple inheritance is still a "good" thing, especially
for mixin-classes. wxPython, for instance, wouldn't be nearly so flexible
without it.
Sure. But Python doesn't _force_ you to do things that way.
Comment