comp.lang.ada
 help / color / mirror / Atom feed
From: "Dmitry A. Kazakov" <mailbox@dmitry-kazakov.de>
Subject: Re: MI Hownotto by Betrand Meyer
Date: Sat, 28 Oct 2006 19:11:14 +0200
Date: 2006-10-28T19:10:58+02:00	[thread overview]
Message-ID: <1gg01bv89foip.16h83zektx82y.dlg@40tude.net> (raw)
In-Reply-To: 1162043687.5674.10.camel@localhost.localdomain

On Sat, 28 Oct 2006 15:54:48 +0200, Georg Bauhaus wrote:

> This week's EiffelWorld column by Bertrand Meyer has a note
> about construction procedures and multiple inheritance.
> I thought it might be interesting given a recent discussion
> in c.l.ada.
> 
> <quote ref="EiffelWorld Electronic Newsletter -- Vol. 33, No 2, Section 4">
> In particular, multiple inheritance just doesn't go well with the
> C++ idea, also retained in Java and C#, that a constructor (creation
> procedure) must start its execution by calling the constructor of
> its parent. As soon as you require this you are ruling out multiple
> inheritance, since with two parents or more there's no good reason for
> executing a particular parent's constructor before the others'; and
> the situation becomes even more hazy when these parents have a common
> ancestor -- repeated inheritance, the so called "diamond" structure.
> Hence complicated rules that probably about twelve people in the world
> understand, and fewer remember.</quote>

Hmm, maybe the quote was taken out of context, but I don't really think
that constructors are responsible "diamond." The issue, as I see it, is
deeper. It is independent on constructors and, notably, even on whether
implementation (like record members) or just interfaces are inherited.

MI definitely adds complexity. In C++ it is quite difficult to deal with,
and construction issues become catastrophic. But what were an alternative
to MI?

-- 
Regards,
Dmitry A. Kazakov
http://www.dmitry-kazakov.de



  reply	other threads:[~2006-10-28 17:11 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-10-28 13:54 MI Hownotto by Betrand Meyer Georg Bauhaus
2006-10-28 17:11 ` Dmitry A. Kazakov [this message]
2006-10-29  3:39   ` Alexander E. Kopilovich
2006-10-29 14:19     ` Dmitry A. Kazakov
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox