This is the mail archive of the gdb@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: cannot subscript something of type <data variable, no debug info>


On Fri, Aug 20, 2004 at 06:23:03PM -0700, Daniel Miller (IMI) wrote:
> I'm trying to debug an application with gdb... I have a struct that is
> declared thus:
> 
> typedef struct S_Module_s
> {
>   unsigned powered_up;
>        ...  other data elements  ...
> } __attribute__ ((__packed__)) S_Module;
> 
> extern S_Module Mod[1];
> 
> I tried compiling both with -g and -ggdb, with no change in the symptoms.

What platform?  What version of GDB?

> I don't seem to be able to display any of the contents of Mod[0], at all....
> I get effects such as:
> 
> (gdb) p Mod[0]
> cannot subscript something of type `<data variable, no debug info>'
> (gdb) p (S_Module) Mod[0]
> No symbol "S_Module" in current context.
> (gdb) p (struct S_Module_s) Mod[0]
> No struct type named S_Module_s.
> 
> What do I have to do to get gdb to recognize my variables??  Virtually every
> GUI-based debugger out there is a wrapper around gdb, to if it's not happy,
> nobody's happy!!!  Please help!!

We'll need a standalone test case, or at least a dump of the debugging
information in the application, to answer this question.

-- 
Daniel Jacobowitz


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