[Bug middle-end/108217] bogus -Warray-bounds with pointer to constant local

2022-12-24 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108217 Andrew Pinski changed: What|Removed |Added Resolution|--- |DUPLICATE Status|UNCONFIRME

[Bug middle-end/108217] bogus -Warray-bounds with pointer to constant local

2022-12-24 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108217 --- Comment #4 from Andrew Pinski --- The problem with const is GCC does not have an idea of a store once and then become constant. an example of that would be: ``` void ExternFunc(const int*); int f(); int Bad() { const int i = f(); const

[Bug middle-end/108217] bogus -Warray-bounds with pointer to constant local

2022-12-24 Thread jhaberman at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108217 Josh Haberman changed: What|Removed |Added Status|RESOLVED|UNCONFIRMED Resolution|DUPLICAT

[Bug middle-end/108217] bogus -Warray-bounds with pointer to constant local

2022-12-24 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108217 Andrew Pinski changed: What|Removed |Added Status|UNCONFIRMED |RESOLVED Resolution|---

[Bug middle-end/108217] bogus -Warray-bounds with pointer to constant local

2022-12-24 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108217 Andrew Pinski changed: What|Removed |Added Keywords|diagnostic |missed-optimization --- Comment #1 from