https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63441

Martin Sebor <msebor at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |msebor at gcc dot gnu.org

--- Comment #2 from Martin Sebor <msebor at gcc dot gnu.org> ---
I still see the warning with today's top of trunk (GCC 4.8) but I agree that
some sort of a diagnostic here seems helpful.

It would be nice if the warning could distinguish between cases where the index
definitely is out of bounds and those where it could be but it's not 100%
certain.  I haven't looked at the implementation to see if this is feasible.

It would also be helpful to have clarity (both for users and GCC developers) on
what diagnostics are meant to be issued under what circumstances.  Based on
some other warnings (-Wuninitialized and -Wmaybe-uninitialized) it seems
reasonable to expect -Warray-bounds to only be issued when an index is
definitely out of bounds (and not when it could be).

Reply via email to