This is the mail archive of the
mailing list for the GCC project.
Re: [PATCH] Fix PR/8268: implement compile time array subscript checking
Am Donnerstag, 7. Dezember 2006 10:51 schrieb Dirk Müller:
> non-overlapping with the vrp determined range. E.g. if you change the i =
> 1; in your testcase to i = 10; it will warn, otherwise it will not. This is
> because I like to use -Werror=array-bounds and therefore do not like false
one possible alternative would be to unconditionally emit the current warning
with -Wall, and make -Warray-bounds also emit when an array subscript "might"
go out of range. I do not consider it useful because it will warn essentially
on any loop that does something non-trivial with array-indices.