Open ghost opened 1 year ago
Hi, this case (https://godbolt.org/z/98PMz1KKz) contains an out-of-bound error (stmt: return arr[9];
). At -O0, the analyzer can report this warning. However, at -O1, -O2, and -O3, the analyzer doesn't report that.
After removing the static
keyword (https://godbolt.org/z/qKohK3eeY), the analyzer can report this warning at -O1, -O2, and -O3.
report: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111213