This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: diagnostic.c reorganization
Zack Weinberg <zack@codesourcery.com> writes:
| I think we're getting carried away here.
I do not believe so.
| This is supposed to be a
| short description of the function for the comment above it, not a
| detailed discussion of the rationale for its use.
I understand that. But I do not believe it is a sufficient reason to
put inaccurate comments in, that is why I commented on the patch as
the diagnostic maintainer.
| I propose to put just
|
| A "pedantic" warning: issues a warning unless -pedantic-errors was
| given on the command line, in which case it issues an error. Use
| this for diagnostics required by the relevant language standard,
| if you have chosen not to make them errors.
|
| Note that these diagnostics are issued independent of the setting
| of the -pedantic command-line switch. To get a warning enabled
| only with that switch, write "if (pedantic) pedwarn (...);"
This is OK.
| Now, since you, Gabriel, have strong opinions on this subject, and
It is not a matter of having strong opinions.
| furthermore you understand the diagnostic.c API in its full detail,
| would you care to write up complete documentation of diagnostic.c for
| the internals manual? That would be an appropriate place to discuss
| when diagnostics should be errors, pedwarns, or plain warnings.
That makes sense.
-- Gaby