The joys of friendship
-
After 10 years or so, I finally got to use friend in C++ again.
friend class CAppDocument;
An extremely specialized case where I could not think of any other way to have a clean design.
-
After 10 years or so, I finally got to use friend in C++ again.
friend class CAppDocument;
An extremely specialized case where I could not think of any other way to have a clean design.
I’m familiar with the concept and have seen it in others code, but after almost 10 years I’ve never used it myself. I suppose this makes me friend virgin.
There is only one Vera Farmiga and Salma Hayek is her prophet! Advertise here – minimum three posts per day are guaranteed.
-
After 10 years or so, I finally got to use friend in C++ again.
friend class CAppDocument;
An extremely specialized case where I could not think of any other way to have a clean design.
-
I’m familiar with the concept and have seen it in others code, but after almost 10 years I’ve never used it myself. I suppose this makes me friend virgin.
There is only one Vera Farmiga and Salma Hayek is her prophet! Advertise here – minimum three posts per day are guaranteed.
Deyan Georgiev wrote:
but after almost 10 years I’ve never used it myself
Me neither. They say I am unfriendly. :-D
-
I'll try to remember that one :laugh:
Espen Harlinn Principal Architect, Software - Goodtech Projects & Services AS My LinkedIn Profile
-
After 10 years or so, I finally got to use friend in C++ again.
friend class CAppDocument;
An extremely specialized case where I could not think of any other way to have a clean design.
I've always found
friend
to be quite useful.Espen Harlinn Principal Architect, Software - Goodtech Projects & Services AS My LinkedIn Profile
-
After 10 years or so, I finally got to use friend in C++ again.
friend class CAppDocument;
An extremely specialized case where I could not think of any other way to have a clean design.
I'm still waiting for the new
sworn enemy
modifier in C# 6.0, as well as thebetray
operator in the dynamic extensions that will allow afriend
class to change at runtime into asworn enemy
classcheers, Chris Maunder The Code Project | Co-founder Microsoft C++ MVP
-
I'm still waiting for the new
sworn enemy
modifier in C# 6.0, as well as thebetray
operator in the dynamic extensions that will allow afriend
class to change at runtime into asworn enemy
classcheers, Chris Maunder The Code Project | Co-founder Microsoft C++ MVP
Is this a proposal? ;)
Espen Harlinn Principal Architect, Software - Goodtech Projects & Services AS My LinkedIn Profile
-
After 10 years or so, I finally got to use friend in C++ again.
friend class CAppDocument;
An extremely specialized case where I could not think of any other way to have a clean design.
C++ - the only place where friends can access your privates ;P
If you need a hammer get C and shut up. If you need a nail gun get C++ and shut up. If you don't need *those* things (and good design should tell you) then by all means get a factory, factory, factory. --code-frog Why would you need to date, when C++ is your soul mate?! --Steve Echols