Bug #18802 2012-11-20 16:42

eklmn

Debugger gets stuck with recursive static members

I'm trying to debug this simple program (gcc 4.7.0, gdb 7.5 on Windows). I add breakpoint at 'return 0' and I try to watch 'var1' but CodeBlocks gets stuck or displays some lengthy recursive tooltip or simply doesn't show var1's value.

struct a

{

int val;

static a s1;

};

a a::s1;

struct b

{

a a1;

static b s2;

};

b b::s2;

int main()

{

a var0 = a::s1;

b var1 = b::s2;

return 0;

}

Category
Debugger
Group
 
Status
Open
Close date
 
Assigned to
tpetrov
tpetrov 2012-12-02 15:41

Put "set print static-members off" in the initial debugger commands and this problem will go away.