On Mon, Mar 24, 2008 at 7:10 AM, pat.morgan74 <[EMAIL PROTECTED]> wrote:

>  I am stuck with a simple problem.Its eating fri=om with in
>
>  My code is as below
>  in the file where main is
>
>  #include class.h
>  int main()
>  {
>  classa ex;
>
>  }
>
>  in .h file
>  class classa
>  {
>  classa();
>  ~classa();
>
>  };
>
>  in the .cc file
>  #include class.h
>  classa::classa()
>  {}
>  classa::~classa()
>  {}
>
>  But g++ is throwing an error in main "undefined reference to
>  classa::classa()"
>  whats am i doing wrong?

It seems like a linking problem. How are you compiling these files?
With a makefile?

-- Brett
------------------------------------------------------------
"In the rhythm of music a secret is hidden;
 If I were to divulge it, it would overturn the world."
 -- Jelaleddin Rumi

Reply via email to