Re: forward declaration error
From: B. v Ingen Schenau (bart_at_ingen.ddns.info)
Date: 05/29/04
- Previous message: Mike Wahler: "Re: newb question: need help with homework assignment"
- In reply to: Scott: "Re: forward declaration error"
- Next in thread: Francis Glassborow: "Re: forward declaration error"
- Reply: Francis Glassborow: "Re: forward declaration error"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Sat, 29 May 2004 19:39:05 +0200
Scott wrote:
> Also, I seem to have setup an interesting circular problem. foo.h
> includes C.h which itself includes B.h - the file I am calling foo.h from.
> Could this be the problem? And if so, how do I go about fixing this?
That could very well be the problem. The only way to resolve it is to break
the circular dependency by moving some of the code to a different file.
You could, for example, move the compare template to a new header
("compare.h"), where you can safely #include "foo.h" without the circular
dependency problem.
> Thanks for any help!
>
> Best,
> Scott
Bart v Ingen Schenau
-- a.c.l.l.c-c++ FAQ: http://www.comeaucomputing.com/learn/faq c.l.c FAQ: http://www.eskimo.com/~scs/C-faq/top.html c.l.c++ FAQ: http://www.parashift.com/c++-faq-lite/
- Previous message: Mike Wahler: "Re: newb question: need help with homework assignment"
- In reply to: Scott: "Re: forward declaration error"
- Next in thread: Francis Glassborow: "Re: forward declaration error"
- Reply: Francis Glassborow: "Re: forward declaration error"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|