Click here to Skip to main content
15,789,362 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: overzealous protection rules Pin
Dave Schumann12-Jul-06 7:50
Dave Schumann12-Jul-06 7:50 
GeneralRe: overzealous protection rules Pin
Zac Howland12-Jul-06 8:08
Zac Howland12-Jul-06 8:08 
GeneralRe: overzealous protection rules Pin
Dave Schumann12-Jul-06 7:59
Dave Schumann12-Jul-06 7:59 
GeneralRe: overzealous protection rules Pin
Zac Howland12-Jul-06 8:14
Zac Howland12-Jul-06 8:14 
Answersolution Pin
Dave Schumann12-Jul-06 7:04
Dave Schumann12-Jul-06 7:04 
GeneralRe: solution Pin
Dave Schumann12-Jul-06 9:25
Dave Schumann12-Jul-06 9:25 
GeneralRe: solution Pin
BadKarma12-Jul-06 9:58
BadKarma12-Jul-06 9:58 
GeneralRe: solution Pin
led mike12-Jul-06 9:53
led mike12-Jul-06 9:53 
Dave Schumann wrote:
I think this is dumb beyond belief.


I disagree. I also agree with some previous postings regarding the poor design. Improved design according to encapsulation principles might look something like this. ( not accounting for "partner" creation issues )

struct A
{
	void doodah()
	{ 	++partner->value; }

protected:
	int& partnerValue(){ return partner->value;}
private:
	A* partner;
	int value;
};

struct B : public A
{
	void foobar()
	{ partnerValue() += 2; }
};


"Just about every question you've asked over the last 3-4 days has been "urgent". Perhaps a little planning would be helpful?"
Colin Angus Mackay in the C# forum

led mike
AnswerRe: overzealous protection rules Pin
Rilhas17-Jul-06 14:43
Rilhas17-Jul-06 14:43 
AnswerRe: overzealous protection rules Pin
David Crow31-Jul-06 11:28
David Crow31-Jul-06 11:28 
QuestionA (simple) Shell Question Pin
Dave Kerr12-Jul-06 5:49
Dave Kerr12-Jul-06 5:49 
QuestionLabeling Slider Bar stops Pin
LCI12-Jul-06 5:36
LCI12-Jul-06 5:36 
AnswerRe: Labeling Slider Bar stops Pin
pgrohs12-Jul-06 5:51
pgrohs12-Jul-06 5:51 
GeneralRe: Labeling Slider Bar stops Pin
LCI12-Jul-06 6:51
LCI12-Jul-06 6:51 
GeneralRe: Labeling Slider Bar stops Pin
pgrohs12-Jul-06 7:05
pgrohs12-Jul-06 7:05 
QuestionRightToLeft property Pin
Elbaz Haviv12-Jul-06 4:17
Elbaz Haviv12-Jul-06 4:17 
AnswerRe: RightToLeft property [modified] Pin
includeh1012-Jul-06 4:33
includeh1012-Jul-06 4:33 
AnswerRe: RightToLeft property Pin
David Crow12-Jul-06 5:36
David Crow12-Jul-06 5:36 
QuestionLocalization in Input String and Log files. Pin
karthik Tamizhmathi12-Jul-06 4:11
karthik Tamizhmathi12-Jul-06 4:11 
QuestionHow to write KeyboardProc() Pin
Max++12-Jul-06 4:09
Max++12-Jul-06 4:09 
AnswerRe: How to write KeyboardProc() Pin
includeh1012-Jul-06 4:22
includeh1012-Jul-06 4:22 
QuestionItems appear twice in 'Find' results Pin
LittleYellowBird12-Jul-06 4:00
LittleYellowBird12-Jul-06 4:00 
Questioncan ChooseFont use ChooseColor? Pin
includeh1012-Jul-06 3:42
includeh1012-Jul-06 3:42 
AnswerRe: can ChooseFont use ChooseColor? Pin
_AnsHUMAN_ 12-Jul-06 6:03
_AnsHUMAN_ 12-Jul-06 6:03 
GeneralRe: can ChooseFont use ChooseColor? Pin
includeh1012-Jul-06 6:45
includeh1012-Jul-06 6:45 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.