comp.lang.ada
 help / color / mirror / Atom feed
From: Colin_Paul_Gloster@ACM.org (Colin Paul Gloster)
Subject: Re: Ada Generic vs. C++ Templates
Date: 17 Apr 2001 08:27:42 GMT
Date: 2001-04-17T08:27:42+00:00	[thread overview]
Message-ID: <slrn9dnrvc.be4v.Colin_Paul_Gloster@tolka.dcu.ie> (raw)
In-Reply-To: qODB6.91$ow5.12326@nnrp1.sbc.net

In article <qODB6.91$ow5.12326@nnrp1.sbc.net>, Pat Rogers wrote:
""Simon Wright" <simon@pushface.org> wrote in message
news:x7v66gdw82g.fsf@smaug.pushface.org...
> Colin_Paul_Gloster@ACM.org (Colin Paul Gloster) writes:
>
> > [..] The Booch Components [..]
> > [..] Pre-Ada 95 it was written on page 192 of "The
> > Design and Evolution of C++" [1] by Bjarne Stroustrup:
> > "[..Grady Booch implemented the Ada [83] version of The Booch Components
> > and he and Mike Vilot later implemented the C++ [of the time] version of
> > The Booch Components. The Ada [83] version] is 125,000 [since you
> > probably speak German I point out that 125,000 in English is equal to one
> > hundred and twentyfive thousand (big); not one hundrend and twentyfive
> > (small)] non-commented source lines compared to the C++ version's 10,000
> > [10000 not 10] lines - inheritance combined with templates can be a very
> > powerful mechanism for organising libraries without loss of performance
> > or clarity", referencing the second edition of "Object-oriented Analysis
> > and Design with Applications" by Grady Booch.
>
> The C++ BCs I was given a copy of when I started maintaining the Ada95
> port have 29_000 non-comment source lines. The Ada95 port has 13_000
> non-comment source lines.

Another point is that the Booch C++ design for the components is very --
repeat very -- different from the Ada design, so comparing sizes is
difficult.  It is not a matter of inheritance.  There is in fact a lot of
replication in the first design that he realized he could avoid, which has
absolutely nothing at all to do with the language chosen.  It is a matter of
the second design benefiting from the first.

Second, there is little inheritance in the C++ version.  It is not the
central design approach, as it would be in say Java or Eiffel.  No one
should conclude that inheritance is the central reason for the difference in
size."

It is peculiar that Bjarne Stroustrup said that the C++ version had 10 000
(non-comment?) source lines but Simon Wright has instead found nearly triple
that excluding comments. The paper quoted from by Mike Vilot and Grady
Booch did not give their sizes. Any one know what is going on?



  reply	other threads:[~2001-04-17  8:27 UTC|newest]

Thread overview: 33+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-04-02 14:28 Ada Generic vs. C++ Templates Josef Widder
2001-04-02 14:38 ` Ted Dennison
2001-04-02 20:57   ` Francois Godme
2001-04-02 21:26     ` Ted Dennison
2001-04-03  0:53       ` David Starner
2001-04-04  7:12         ` Pascal Obry
2001-04-04 12:37         ` Stephen Leake
2001-04-04 14:16         ` Ted Dennison
2001-04-03 22:09       ` Francois Godme
2001-04-04 16:17         ` Brian Rogoff
2001-04-04 16:21         ` Jeffrey Carter
2001-04-04 16:49           ` Ayende Rahien
2001-04-05 22:31             ` Colin Paul Gloster
2001-04-04 16:56           ` Ted Dennison
2001-04-04 17:02             ` Ayende Rahien
2001-04-05  0:35         ` James Rogers
2001-04-05  3:38           ` DuckE
2001-04-05 14:25             ` Marin David Condic
2001-04-05 20:32               ` Robert A Duff
2001-04-05 21:04                 ` Marin David Condic
2001-04-06 16:19                   ` Robert A Duff
2001-04-06  0:37             ` James Rogers
2001-04-06 10:38               ` Colin Paul Gloster
2001-04-11  3:33                 ` Stephen Howe
2001-04-11 14:33                   ` Colin Paul Gloster
2001-04-04 13:24 ` Georg Bauhaus
2001-04-05  8:46   ` Jean-Marc Bourguet
2001-04-04 17:30 ` Ehud Lamm
2001-04-05 22:04   ` Colin Paul Gloster
2001-04-10  7:03     ` Simon Wright
2001-04-13 14:11       ` Pat Rogers
2001-04-17  8:27         ` Colin Paul Gloster [this message]
2001-04-08  5:00 ` Lao Xiao Hai
replies disabled

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