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

--- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
hmm, this code seems like undefined code. If I change 1 to 2 as you are
accessing 2 elements via operator[], there is no warning ...

The warning seems correct and even says 1 bounds is above the array bounds of
[1].

The location of the warning seems off but I don't think the warning in this
case is false positive though.

Maybe it is due to the reduced testcase though.

Reply via email to