Re: forward declaration error

From: B. v Ingen Schenau (bart_at_ingen.ddns.info)
Date: 05/29/04

  • Next message: Arthur J. O'Dwyer: "Re: newb question: need help with homework assignment"
    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/
    

  • Next message: Arthur J. O'Dwyer: "Re: newb question: need help with homework assignment"

    Relevant Pages

    • Re: ASP .NET Redirect Question.
      ... it actually should redirect back to my calling page and ... returning to my calling page. ... "Scott Allen" wrote: ... >>it needs a dedicated IP address, if my local workstation isn't sufficient. ...
      (microsoft.public.dotnet.framework.aspnet)
    • Re: temporary file in C++
      ... Scott wrote: ... C++ of course inherited tmpfile() from C. ... a.c.l.l.c-c++ FAQ: http://www.comeaucomputing.com/learn/faq ...
      (alt.comp.lang.learn.c-cpp)
    • Re: CDR quality / reliability problems
      ... I've seen other cases where I knew far more about a subject than Scott ... On the case of the NPR satellite system, I was trying to learn the answers ... did not jive with the information I was reading in the CDSpeed FAQ. ... I was seeing were due to one of the other 4 reasons. ...
      (rec.audio.pro)
    • Re: Who is 888-695-9405, and why do they keep calling me?
      ... It would be nice to know who's calling. ... Scott is generally correct. ... local police - I encouraged her to do so, I even gave her the number to ... The phone company will put a trap on your phone, ...
      (misc.consumers)
    • Re: Insurance Co. using EZPASS data (Re: Article: Cameras finding stolen cars)
      ... with because you are an ignoramus, does NOT mean it is logical or is ... Hmm, looking back on Scott Kozel's post about you, and even given the ... Try acting your age for once and quit calling me names and using ad ... Piggy is like a little pet that we keep around because he is ...
      (misc.transport.road)