From mboxrd@z Thu Jan 1 00:00:00 1970
X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me
X-Spam-Level:
X-Spam-Status: No, score=-1.3 required=5.0 tests=BAYES_00,INVALID_MSGID
autolearn=no autolearn_force=no version=3.4.4
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 103376,73036d0217be91e2
X-Google-Attributes: gid103376,public
From: tmoran@bix.com
Subject: Re: Inheritance versus Generics
Date: 1997/04/27
Message-ID: <5k0948$fa7@lotho.delphi.com>#1/1
X-Deja-AN: 237798583
Organization: Delphi Internet Services
Newsgroups: comp.lang.ada
Date: 1997-04-27T00:00:00+00:00
List-Id:
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. ;)