comp.lang.ada
 help / color / mirror / Atom feed
* Inheritance versus Generics
@ 1997-04-24  0:00 Craig Smith
  1997-04-25  0:00 ` Robert A Duff
                   ` (5 more replies)
  0 siblings, 6 replies; 28+ messages in thread
From: Craig Smith @ 1997-04-24  0:00 UTC (permalink / raw)



Generics were a very power feature of Ada-83.  With the OO features
introduced into Ada-95 (in particuliar, the tagged record and ability to
inherit), are Generics obsolute?  I would guess since several features
were added to generics (like generic formal package parameters), the
answer is no.  Does anyone have any thoughts on this?

Craig D. Smith




^ permalink raw reply	[flat|nested] 28+ messages in thread
* Re: Inheritance versus Generics
@ 1997-04-27  0:00 tmoran
  0 siblings, 0 replies; 28+ messages in thread
From: tmoran @ 1997-04-27  0:00 UTC (permalink / raw)



In <5juemo$bca@felix.seas.gwu.edu> Michael Feldman gives
>A Few "Sound Bites" on Object-Oriented Programming
  After about 9 months of fairly heavy use of tagged types, it seems
to me that they are a powerful tool, but tend easily to lead away
from correctness, understandability, and reusability.
  It's easy to wind up calling a different routine than you thought.
  It can be difficult to realize that you're calling the wrong routine.
  Base types easily have too many primitives, and each generation of
descendants adds a few, resulting in a supposeduly reusable
encapsulated component that has a very large 'surface area' that the
re-user must understand. At each generation the conceptual nature
of the object tends to be slightly distorted (analogous to the
transmission of rumors), and these minor distortions tend to add
up to significant changes in the original concept.  It may develop
that the newer generations, and the uses of their objects, show
the Ur-object to be less than ideal, but it's much too late to change.
  Orthogonally, there is a problem with the mushiness of the word
'object' in the industry.  Thus in MS Windows, an 'object' more or
less means 'a handle to a private data record'.  These have somewhat
different behavior than one might expect an abstract 'menu object'
or 'pen object' to have.  Another source of confusion and thus error.
  Inheritance does allow some powerful ways of doing things, and
perhaps after 5-10 years, when the next Silver Bullet comes along,
we will all use OO flawlessly.  ;)




^ permalink raw reply	[flat|nested] 28+ messages in thread
* Re: Inheritance versus Generics
@ 1997-05-03  0:00 tmoran
  0 siblings, 0 replies; 28+ messages in thread
From: tmoran @ 1997-05-03  0:00 UTC (permalink / raw)



>I can read a language definition (carefully), and feel some confidence
>in criticizing it, despite the fact that I haven't invested several
>years of my life programming in it.  Otherwise, how can we make progress
>in language design?  There are thousands of languages out there -- the
>best we can expect from language designers is to be familiar with them
>by reading -- not direct experience.  Of course, there are those who
  There is a third alternative:  look at the results of thousands of
real programmers using the language.  It may be impractical for language
designers to have lots of direct experience in lots of languages, but
the history of science since the Greeks suggests there are real limits
on how far you can get by merely writing about other's ideas, without
going into the real world and trying out your ideas to see how they work
in practice.
  Take a look at "Strategic Directions in Programming Languages" in the
new ACM Computing Surveys.  Under "Exceptions", it says "introduced in
PL/1 but extensively studied and formalized in ML; similar concepts
appeared later in C++."  Did the "extensive study and formalization" in
ML include having thousands of real programmers, of varying excellence,
write millions of lines of code using exceptions in various
idiosyncratic ways, thus providing grist for the language designers to
fine tune the syntax, semantics, and guidelines about exceptions?




^ permalink raw reply	[flat|nested] 28+ messages in thread

end of thread, other threads:[~1997-05-04  0:00 UTC | newest]

Thread overview: 28+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1997-04-24  0:00 Inheritance versus Generics Craig Smith
1997-04-25  0:00 ` Robert A Duff
1997-04-25  0:00 ` Tucker Taft
1997-04-25  0:00 ` Mats Weber
1997-04-27  0:00   ` Matthew Heaney
1997-04-27  0:00     ` Robert Dewar
1997-04-28  0:00       ` Bertrand Meyer
1997-05-03  0:00         ` Robert A Duff
1997-05-03  0:00           ` Robert Dewar
1997-05-03  0:00         ` Jon S Anthony
1997-05-04  0:00           ` Robert Dewar
1997-04-29  0:00     ` bertrand
1997-04-29  0:00       ` Robert Dewar
1997-04-25  0:00 ` Lionel Draghi
1997-04-25  0:00 ` Robert Dewar
1997-04-25  0:00   ` Michael F Brenner
1997-04-25  0:00     ` Robert Dewar
1997-04-27  0:00       ` Nick Roberts
1997-04-29  0:00         ` Michael F Brenner
1997-05-02  0:00           ` John G. Volan
1997-05-02  0:00           ` Nick Roberts
1997-05-03  0:00             ` Robert Dewar
1997-04-29  0:00       ` Mats Weber
1997-05-01  0:00         ` Robert Dewar
1997-04-26  0:00   ` Michael Feldman
1997-04-28  0:00 ` Martin Lorentzon
  -- strict thread matches above, loose matches on Subject: below --
1997-04-27  0:00 tmoran
1997-05-03  0:00 tmoran

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