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: fac41,c52c30d32b866eae X-Google-Attributes: gidfac41,public X-Google-Thread: 1108a1,c52c30d32b866eae X-Google-Attributes: gid1108a1,public X-Google-Thread: 103376,2ea02452876a15e1 X-Google-Attributes: gid103376,public From: John G. Volan Subject: Re: Real OO Date: 1996/03/20 Message-ID: <4ip7eb$66v@dayuc.dayton.saic.com>#1/1 X-Deja-AN: 143392953 distribution: world references: <4id031$cf9@dayuc.dayton.saic.com> <314f6cf8.682571966@news.dimensional.com> content-type: text/plain; charset=ISO-8859-1 x-xxmessage-id: organization: Science Applications International Corp. (SAIC) mime-version: 1.0 newsgroups: comp.lang.ada,comp.lang.eiffel,comp.object Date: 1996-03-20T00:00:00+00:00 List-Id: In article <4ik3j7$cl6@watnews1.watson.ibm.com> Norman H. Cohen, ncohen@watson.ibm.com writes: >In article <4id031$cf9@dayuc.dayton.saic.com>, John G. Volan > writes (concerning the division of a >tagged type's interfaces into multiple subinterfaces for different >clients): ... >|> (In fact, I'd say in general that any operation ought to be classwide if >|> it isn't explicitly a primitive. IMHO, only under very rare >|> circumstances should a non-primitive operation restrict a parameter to >|> accept only a specific root type but not any of its derived types.) > >By instinct, I'm wary of such sweeping generalizations. However, it >would appear that John's approach is the appropriate one in many >circumstances. Of course it's prudent to be wary of generalization -- or rather, it's prudent to be wary of slavish devotion to generalization. What I should have said was: "If an operation isn't explicitly a primitive, then the default choice ought to be to make it classwide. Making it specific to the root type is still a possibility, but that choice should carefully reasoned, and the justifications for it should be documented." ------------------------------------------------------------------------ Internet.Usenet.Put_Signature ( Name => "John G. Volan", E_Mail => "John_Volan@dayton.saic.com", Favorite_Slogan => "Ada95: The *FIRST* International-Standard OOPL", Humorous_Disclaimer => "These opinions are undefined by SAIC, so" & "any use would be erroneous ... or is that a bounded error now?" ); ------------------------------------------------------------------------