[Bug c/49754] Let gcc warn about all uninitialized variables

2011-07-15 Thread giecrilj at stegny dot 2a.pl
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49754 --- Comment #5 from Christopher Yeleighton 2011-07-15 11:00:28 UTC --- (In reply to comment #3) > (In reply to comment #2) > > Since (x) is uninitialized, so is (x.i). > > But what if x.i gets initialized, is x still uninitialized? If (x.i) den

[Bug c/49754] Let gcc warn about all uninitialized variables

2011-07-15 Thread redi at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49754 --- Comment #4 from Jonathan Wakely 2011-07-15 10:16:12 UTC --- Just to be clear - I completely agree that uninit'd warnings need improving, I'm not objecting to that. But in my experience (mostly C++) I'd prefer to have it tracked at the more f

[Bug c/49754] Let gcc warn about all uninitialized variables

2011-07-15 Thread redi at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49754 --- Comment #3 from Jonathan Wakely 2011-07-15 09:56:49 UTC --- (In reply to comment #2) > Since (x) is uninitialized, so is (x.i). But what if x.i gets initialized, is x still uninitialized? struct X { int i; }; struct Y { int i; int j; }; i

[Bug c/49754] Let gcc warn about all uninitialized variables

2011-07-15 Thread giecrilj at stegny dot 2a.pl
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49754 --- Comment #2 from Christopher Yeleighton 2011-07-15 09:35:42 UTC --- (In reply to comment #1) > (In reply to comment #0) > > == Expected Results == > > foo.c: In function ‘foo’: > > foo.c:2:?: warning: ‘x’ is used uninitialized in this functi

[Bug c/49754] Let gcc warn about all uninitialized variables

2011-07-15 Thread redi at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49754 --- Comment #1 from Jonathan Wakely 2011-07-15 08:36:30 UTC --- (In reply to comment #0) > == Expected Results == > foo.c: In function ‘foo’: > foo.c:2:?: warning: ‘x’ is used uninitialized in this function It should really warn if 'x.i' is us