https://gcc.gnu.org/bugzilla/show_bug.cgi?id=72754
Eric Gallager <egallager at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |egallager at gcc dot gnu.org --- Comment #1 from Eric Gallager <egallager at gcc dot gnu.org> --- gcc now produces at least 1 error in c++ mode: $ /usr/local/bin/gcc -c -S -Wall -Wextra -Wpedantic -xc 72754.cc 72754.cc:1:14: error: flexible array member in a struct with no named members struct { int a[]; } *p; ^ 72754.cc:4:15: error: flexible array member in a struct with no named members struct { int a[]; } *q; ^ $ /usr/local/bin/g++ -c -S -Wall -Wextra -Wpedantic -xc++ 72754.cc 72754.cc:1:16: warning: ISO C++ forbids flexible array member ‘a’ [-Wpedantic] struct { int a[]; } *p; ^ 72754.cc:4:17: warning: ISO C++ forbids flexible array member ‘a’ [-Wpedantic] struct { int a[]; } *q; ^ 72754.cc:4:17: error: flexible array member ‘S::<unnamed struct>::a’ in an otherwise empty ‘struct S’ 72754.cc:1:22: warning: ‘p’ defined but not used [-Wunused-variable] struct { int a[]; } *p; ^ $ /sw/opt/llvm-3.1/bin/clang++ -c -S -Wall -Wextra -pedantic -xc++ 72754.cc 72754.cc:1:14: warning: flexible array member 'a' in otherwise empty struct is a GNU extension [-pedantic,-Wgnu] struct { int a[]; } *p; ^ 72754.cc:4:15: warning: flexible array member 'a' in otherwise empty struct is a GNU extension [-pedantic,-Wgnu] struct { int a[]; } *q; ^ 72754.cc:1:22: warning: unused variable 'p' [-Wunused-variable] struct { int a[]; } *p; ^ 3 warnings generated. $ Any idea when this was half-fixed?