comp.lang.ada
 help / color / mirror / Atom feed
From: "Dmitry A. Kazakov" <mailbox@dmitry-kazakov.de>
Subject: Re: How to hide inherited implementation of a public interface?
Date: Sat, 22 Mar 2014 09:31:56 +0100
Date: 2014-03-22T09:31:56+01:00	[thread overview]
Message-ID: <1302npsqvdkko.1uwmf53e7dhkn$.dlg@40tude.net> (raw)
In-Reply-To: lgige4$3oh$1@loke.gir.dk

On Fri, 21 Mar 2014 18:02:28 -0500, Randy Brukardt wrote:

> Full multiple inheritance CAN be implemented, but it's expensive enough in 
> compiler and language complexity that the costs outweight the value.

In the real-life project lack I am working on of proper MI led to a massive
cut-and-paste code explosion on the scale 1 to 1000, at least.

> The 
> halfway Java-like solution is easier to implement but makes no one happy. We 
> should have told the multiple inheritance nuts to forget it, because it 
> makes no sense for Ada.

MI is not a language property, it is more of software design. You cannot
get rid of the fact that software engineers will keep on trying to reuse
code, sharing the code implementing file reading in the code of read-only
and read-write files. This is a sound design. It is the opposite [*] that
does not make sense. If the language does not support sound software design
decisions, well, that is what we call a language flaw.

------------
* The standard library is full of flaws caused by not using MI. From minor
issues that Root_Stream_Type does not implement Limited_Controled, to
massive mess that Character and Wide_Character to don't share common
interface.

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

      reply	other threads:[~2014-03-22  8:31 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-03-21 12:53 How to hide inherited implementation of a public interface? Natasha Kerensikova
2014-03-21 13:54 ` Dmitry A. Kazakov
2014-03-21 16:05   ` Natasha Kerensikova
2014-03-21 17:58 ` Jeffrey Carter
2014-03-21 20:14   ` Dmitry A. Kazakov
2014-03-21 23:02     ` Randy Brukardt
2014-03-22  8:31       ` Dmitry A. Kazakov [this message]
replies disabled

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