This is the mail archive of the
mailing list for the GCC project.
Re: [PATCH/middle-end/diagnostic] Do not warn about unused out of bounds array refs
On Tuesday, 20. March 2007, Jakub Jelinek wrote:
> But if you never dereference it and it doesn't escape, then it is
> completely harmless.
part of the idea of the warning was to discover when somebody takes address of
an element way beyond the array limit.
> As is -Warray-bounds just causes too many false positives, see
> PR31227 or e.g. yesterday when I tried to bootstrap with obj-c++
I don't know what the obj-c++ issue is (is there a PR about it?), but I can
remove the warning for taking addresses of array refs with a two liner patch