comp.lang.ada
 help / color / mirror / Atom feed
From: kst@telesoft.com (Keith Thompson @pulsar)
Subject: Re: Ichibah flames, and flames out over, Ada 9X
Date: Sat, 13 Mar 1993 03:11:04 GMT
Date: 1993-03-13T03:11:04+00:00	[thread overview]
Message-ID: <1993Mar13.031104.21673@telesoft.com> (raw)
In-Reply-To: 1993Mar12.160136.6106@evb.com

In article <1993Mar12.160136.6106@evb.com> pole@evb.com (Tom Pole) writes:
> [...]
> If Ada wants to attract/convince/whatever programmers to use Ada, and 
> that it is truly an OOPL, then Ada should use the accepted (de facto standard)
> terminology of OORequirements Analysis, OODesign, OOetc.
> 
> A class is a class. If Ada wants to add the ability to have 
> inheritance/specialization similar to what is available in other
> OOPL's, the OO world calls the common definition
> of a type which supports specialization a class, and instantiations
> of that type objects. Ada can use the same terms if it wishes.
> [...]

Many years ago, when I first read the preliminary Ada reference manual
(the 1979 version), I had a lot of trouble understanding the section
on access types, with its discussion of access values "designating"
objects and so forth.

Not long after that, I realized that access types are (essentially)
what Pascal calls pointer types.  (Pascal was the language I was most
familiar with at the time.)  The current (1983) Ada reference manual
has a note explaining that "Access values are called pointers or
references in other languages" (3.8:10); the 1979 preliminary version
probably had a similar note, but I missed it at first.

Once I had made that connection, I didn't have any problem understanding
what access types are and how they work; most of what I had learned about
Pascal pointer types applied almost directly to Ada access types.

My point is that these minor differences in terminology (pointers vs.
access types, classes vs. tagged types, functions returning void vs.
procedures) really don't matter.  It should take literally no more than
a few seconds to make the connection between similar features in
different languages, once the correlation is pointed out.

Furthermore, as others have mentioned, a C++ class is both a type and a
unit of encapsulation.  The Ada equivalent of a C++ class would be a
package containing declarations for a single type and its operations,
but Ada also allows declarations of any set of logically related
entities to be grouped into a package.  In my opinion, this is a
considerable advantage of Ada over C++.

Ok, so I'm simultaneously arguing that the difference in terminology
doesn't matter because the constructs are the same, and that the
terminology should be different because the constructs are different.
You expect consistency in a Usenet posting?  8-)}

Seriously, I believe that Ada 9X tagged types provide essentially the
same capabilities as C++ classes, in a way that fits well into the
existing Ada 83 framework of packages, derived types, and so on.  I see
little point in making the purely syntactic change from "type Foo is
tagged record ..." to "class type Foo is record ...".  Any more
extensive change, like making classes a unit of encapsulation, would do
too much violence to the overall structure of the language.

The Ada 9X reference manual should probably have a note pointing out
the correlation between tagged types and the various class constructs
of C++ and other object-oriented languages.
-- 
Keith Thompson (The_Other_Keith)  kst@telesoft.com
TeleSoft^H^H^H^H^H^H^H^H Alsys, Inc.
5959 Cornerstone Court West, San Diego, CA, USA, 92121-9891
"Listen to me, people!  We must stick them with quills -- it's the only way!"



  parent reply	other threads:[~1993-03-13  3:11 UTC|newest]

Thread overview: 54+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1993-03-10 20:15 Ichibah flames, and flames out over, Ada 9X John Goodsen
1993-03-10 22:41 ` David Emery
1993-03-12 16:01   ` Tom Pole
1993-03-12 22:59     ` Charles H. Sampson
1993-03-16 17:35       ` Classes versus tagged types was " Tom Pole
1993-03-18 16:28         ` In favor of tagged types (was Classes versus tagged types was Ichibah flames, and flames out over, Ada 9X) Stephane Barbey
1993-03-19 18:13           ` Larry M. Jordan
1993-03-13  3:11     ` Keith Thompson @pulsar [this message]
1993-03-14 15:03       ` Ichibah flames, and flames out over, Ada 9X Fergus James HENDERSON
1993-03-15 23:19       ` Harry Koehnemann
1993-03-16  2:50         ` Michael Feldman
1993-03-17 18:18         ` Robert Firth
1993-03-12 22:02   ` Anthony Howell
1993-03-11  8:33 ` Ichibah [sic] " Magnus Kempe
  -- strict thread matches above, loose matches on Subject: below --
1993-03-11 15:13 Ichibah " Tucker Taft
1993-03-10 20:39 John Goodsen
1993-03-07 19:15 John Goodsen
1993-03-08  0:45 ` David Emery
1993-03-08 15:36 ` Tucker Taft
1993-03-08 16:28   ` Michael Feldman
1993-03-08 22:15     ` Gregory Aharonian
1993-03-09 14:20       ` Tucker Taft
1993-03-09 14:55         ` C. Michael Holloway
1993-03-10 14:51         ` Gregory Aharonian
1993-03-09 17:12       ` Harry Koehnemann
1993-03-09 20:54         ` Michael Feldman
1993-03-09 20:14       ` Larry M. Jordan
1993-03-09 17:49     ` Harry Koehnemann
1993-03-09 21:01       ` Michael Feldman
1993-03-09 18:12   ` Tom Wicklund
1993-03-09 18:53   ` Larry M. Jordan
1993-03-09 20:24     ` David Weller
1993-03-09 21:03       ` Michael Feldman
1993-03-12 14:49         ` Tucker Taft
1993-03-12 23:54           ` Michael Feldman
1993-03-16 17:34   ` Robert Firth
1993-02-26 22:58 Bob Munck
1993-02-28 18:42 ` Don Tyzuk
1993-03-04 22:44   ` news
1993-03-05  2:39     ` Richard Pattis
1993-03-05 11:36     ` David Weller
1993-03-05 12:06     ` Don Tyzuk
1993-02-26 16:26 enterpoop.mit.edu!linus!agate!howland.reston.ans.net!paladin.american.edu
1993-02-26 14:35 David Emery
1993-02-25 23:51 Mark A Biggar
1993-02-24 21:10 John Goodsen
1993-02-25  3:48 ` agate!usenet.ins.cwru.edu!magnus.acs.ohio-state.edu!cis.ohio-state.edu!ne
1993-02-25 17:08   ` Harry Koehnemann
1993-03-01 15:59     ` Tucker Taft
1993-03-02  7:43       ` Dag Bruck
1993-02-22 23:56 Robert I. Eachus
1993-02-22 19:32 asuvax!ennews!enuxhb.eas.asu.edu!koehnema
1993-02-17 14:50 agate!howland.reston.ans.net!wupost!darwin.sura.net!mlb.semi.harris.com!d
1993-02-17 11:54 agate!howland.reston.ans.net!sol.ctr.columbia.edu!The-Star.honeywell.com!
replies disabled

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