static and protection
Kyle Furlong
kylefurlong at gmail.com
Wed Mar 1 16:43:07 PST 2006
Jarrett Billingsley wrote:
> "Hasan Aljudy" <hasan.aljudy at gmail.com> wrote in message
> news:du56te$1rn5$1 at digitaldaemon.com...
>> friendship works, my point was that it shouldn't be there in the first
>> place, it's not part of the OO paradigm, it's a hack introduced by C++
>
> Just because it's not part of some archaic OO paradigm doesn't mean it can't
> exist. It might be a hack, but I think it's kind of borne out of necessity.
> Sometimes the rules in OO need to be .. bent a little, and friend classes do
> just that. I mean, which would you rather have? Two classes that need to
> work together friended so they can access each others' internals, and so no
> one else can access those internals? Or be required to make those internals
> public just so those classes can work together? If two classes really need
> to work together but still need to be separate classes, I really don't see
> any other solution..
>
>
Well, do people use your *ORGANS* when you work with them?
More information about the Digitalmars-d
mailing list