This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH, PR c++/40892] Fix maybe_warn_cpp0x i18n problems
On Wed, 18 Nov 2009, Paolo Bonzini wrote:
> The problem is that sometimes you have 10-20 possibilities for the "kind", for
> example in bad_specifiers
>
> - bad_specifiers (decl, "type", virtualp, quals != NULL_TREE,
> - bad_specifiers (decl, "parameter", virtualp, quals != NULL_TREE,
> - bad_specifiers (decl, "field", virtualp, quals != NULL_TREE,
> - bad_specifiers (decl, "variable", virtualp, quals != NULL_TREE,
>
> each of these four choices is used in three error messages, thus complicating
> the code.
I don't see four choices in three error messages as being a problem at
all. In c-typeck.c there are ten calls to the WARN_FOR_ASSIGNMENT macro,
each of which has four possible messages, for example.
--
Joseph S. Myers
joseph@codesourcery.com