This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC 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]

[Bug c/36299] spurious and undocumented warning with -Waddress for a == 0 when a is an array


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36299

--- Comment #5 from Vincent LefÃvre <vincent at vinc17 dot org> 2011-03-01 15:05:19 UTC ---
Under Debian, I can no longer reproduce the problem with GCC 4.5.2:

$ gcc-4.5 -Wall warn-nulladdress.c
$ gcc-4.5 -Waddress warn-nulladdress.c
$ gcc-4.4 -Wall warn-nulladdress.c
warn-nulladdress.c: In function âmainâ:
warn-nulladdress.c:14: warning: the address of âaâ will never be NULL
$ gcc-4.4 -Waddress warn-nulladdress.c
warn-nulladdress.c: In function âmainâ:
warn-nulladdress.c:14: warning: the address of âaâ will never be NULL

So, I assume that it has been fixed anyway. Do you confirm?


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