[Bug c++/71290] New: [6/7 Regression] Flexible array member is not diagnosed with -pedantic
miyuki at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Thu May 26 12:08:00 GMT 2016
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71290
Bug ID: 71290
Summary: [6/7 Regression] Flexible array member is not
diagnosed with -pedantic
Product: gcc
Version: 7.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: miyuki at gcc dot gnu.org
Target Milestone: ---
We used to warn for:
$ cat test.cc
struct S {
int i;
unsigned arr[];
};
$ /opt/gcc-5.3.0/bin/g++ test.cc -pedantic
test.cc:3:18: warning: ISO C++ forbids zero-size array 'arr' [-Wpedantic]
unsigned arr[];
Starting with r231665 the warning is gone.
More information about the Gcc-bugs
mailing list