incomplete type in gdb?

Hi,

I’ve occasionally noticed problems with incomplete types in gdb.
For example, if I have a structure

struct Dummystruct {
double test1[4];
double test2[4][4];
};
typedef struct Dummystruct Dummystruct;

Dummystruct ds;

And I fire up gdb, and try to print it:

(gdb) print ds
$1 = {test1 = , test2 = {{0, 0, 0, 0}, {
0, 0, 0, 0}, {0, 0, 0, 0}, {0, 0, 0, 0}}}

I get an incomplete type for one of the structure elements.
This isn’t the first time I’ve observed this sort of behavior. Have
others seen this? my gcc says its release 2.95.2 19991024, my
gdb says its 4.17. Should I try to catch the bug and send it in
or is there already a fix for this?

Thanks,

Arthur

I can’t reproduce this with your example. Can you try making
a small test case?

Arthur <3_arthur@my-deja.com> wrote:

Hi,

I’ve occasionally noticed problems with incomplete types in gdb.
For example, if I have a structure

struct Dummystruct {
double test1[4];
double test2[4][4];
};
typedef struct Dummystruct Dummystruct;

Dummystruct ds;

And I fire up gdb, and try to print it:

(gdb) print ds
$1 = {test1 = , test2 = {{0, 0, 0, 0}, {
0, 0, 0, 0}, {0, 0, 0, 0}, {0, 0, 0, 0}}}

I get an incomplete type for one of the structure elements.
This isn’t the first time I’ve observed this sort of behavior. Have
others seen this? my gcc says its release 2.95.2 19991024, my
gdb says its 4.17. Should I try to catch the bug and send it in
or is there already a fix for this?

Thanks,

Arthur


cburgess@qnx.com

OK…I guess it’s not a common problem…
I’ll try to isolate it and post code within a few days.

Thanks,

-Arthur

<cburgess@qnx.com> wrote in message news:900l34$oc2$1@nntp.qnx.com

I can’t reproduce this with your example. Can you try making
a small test case?

Arthur <> 3_arthur@my-deja.com> > wrote:
Hi,

I’ve occasionally noticed problems with incomplete types in gdb.
For example, if I have a structure

struct Dummystruct {
double test1[4];
double test2[4][4];
};
typedef struct Dummystruct Dummystruct;

Dummystruct ds;

And I fire up gdb, and try to print it:

(gdb) print ds
$1 = {test1 = , test2 = {{0, 0, 0, 0}, {
0, 0, 0, 0}, {0, 0, 0, 0}, {0, 0, 0, 0}}}

I get an incomplete type for one of the structure elements.
This isn’t the first time I’ve observed this sort of behavior. Have
others seen this? my gcc says its release 2.95.2 19991024, my
gdb says its 4.17. Should I try to catch the bug and send it in
or is there already a fix for this?

Thanks,

Arthur



\

cburgess@qnx.com