On 07/29/2016 09:22 AM, Marek Polacek wrote:
As outlined in the PR, for code such as
struct S {
int :1;
int a[];
};
the error message "flexible array member in otherwise empty struct" is not
entirely correct, because the structure isn't otherwise empty. Martin Sebor
suggested to rephrase the error message as in the following.
Bootstrapped/regtested on x86_64-linux, ok for trunk?
2016-07-29 Marek Polacek <pola...@redhat.com>
PR c/71742
* c-decl.c (finish_struct): Rephrase an error message.
* gcc.dg/940510-1.c: Adjust dg-error.
* gcc.dg/c99-flex-array-1.c: Likewise.
* gcc.dg/c99-flex-array-typedef-1.c: Likewise.
OK
jeff