Message-ID: <36329321.21F4ACAD@montana.com> Date: Sat, 24 Oct 1998 20:55:29 -0600 From: bowman X-Mailer: Mozilla 4.5b2 [en] (Win95; I) X-Accept-Language: en MIME-Version: 1.0 To: djgpp AT delorie DOT com Subject: Re: construction has been delayed due to somebody's stupidity (most likely my own) References: <5zeY1.843$SI2 DOT 270 AT news DOT cwix DOT com> <3631E505 DOT 4773CBD3 AT montana DOT com> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Reply-To: djgpp AT delorie DOT com Mike Ruskai wrote: > > >int main(void) > >{ > > MyClass instance(); // point of interest > > instance.say_hi(); > >} > This is bad because you're declaring a function instead of defining a > variable. sigh. yes, one too many cut and pastes. Make that three ways not to do it. It is interesting that one can declare a function returning MyClass, never define or use it, and the compiler never says a word, while it will emit warnings for used variables. so much for malformed code and compiler oddities. I hope the original poster got his problem solved.