This is the mail archive of the gdb-patches@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [RFA] Missing #include in objfiles.h?


On Thu, Aug 01, 2002 at 04:48:05PM -0400, Andrew Cagney wrote:

>I'm not sure if this is intended or not, but objfiles.h relies on
>symfile.h for the definition of certain structures. However, objfiles
>does not #include symfile. So my attempt to include objfiles without
>prior including symfile caused a compilation error.


What exactly? A mindless grep suggests opaque references but not a hard dependency. Adding an opaque ``struct sym_fns;'' to avoid an include is ok.

Here are the fields in struct objfile that cause the compilation error:

    /* Vectors of all partial symbols read in from file.  The actual data
       is stored in the psymbol_obstack. */

    struct psymbol_allocation_list global_psymbols;
    struct psymbol_allocation_list static_psymbols;

So the full definition is need for this file to compile.
Ah!  In that case, yes definitly.

Andrew



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]