Newsgroups: comp.lang.c++,comp.lang.smalltalk,comp.lang.eiffel,comp.lang.ada,comp.object,comp.software-eng
Path: cantaloupe.srv.cs.cmu.edu!rochester!udel-eecis!gatech!rutgers.rutgers.edu!news.columbia.edu!panix!news.mathworks.com!news.maxwell.syr.edu!feed1.news.erols.com!news.ecn.uoknor.edu!munnari.OZ.AU!uunet!in3.uu.net!uucp3.uu.net!alexandria.organon.com!alexandria!jsa
From: jsa@alexandria (Jon S Anthony)
Subject: Re: What is wrong with OO ?
In-Reply-To: shapcott@wallaby.cig.mot.com's message of 12 Feb 1997 21:19:51
	GMT
Message-ID: <JSA.97Feb14201907@alexandria>
Sender: news@organon.com (news)
Organization: Organon Motives, Inc.
References: <5dopri$dei@news4.digex.net> <JSA.97Feb11200125@alexandria>
	<5dtc5n$554@trotsky.cig.mot.com>
Date: Sat, 15 Feb 1997 01:19:07 GMT
Lines: 35
Xref: glinda.oz.cs.cmu.edu comp.lang.c++:247985 comp.lang.smalltalk:51643 comp.lang.eiffel:18460 comp.lang.ada:57619 comp.object:61169 comp.software-eng:53817

In article <5dtc5n$554@trotsky.cig.mot.com> shapcott@wallaby.cig.mot.com (David B. Shapcott [C]) writes:

> In article <JSA.97Feb11200125@alexandria>,
> Jon S Anthony <jsa@alexandria> wrote:
> >[...] If you decide
> >you need a new "friend" you have to go back and _change_ the source
> >(which you may not even have accesss to!)
> 
> But you do have access to the `part' of the source you need: the
> header file, where friendship declarations are made.  Friendship has
> no runtime implications and so classes do not need to be recompiled.

First, it may not be in a header file (of course that may be poor
design, but...)  Second, the point is you have to change existing
source in order to effect friendship, i.e., you are changing source to
effect something _outside the context_ of what that source represents.
That's always a dodgy thing to do.


> (Virtual fns, on the other hand, do have runtime implications, and
> polymorphism cannot be changed without recompilation.  Code linked
> with different polymorhism models would likely die or at least
> behave unpredictably the first time it tried to call through the
> vtable).

Agreed.

/Jon
-- 
Jon Anthony
Organon Motives, Inc.
Belmont, MA 02178
617.484.3383
jsa@organon.com

