diagnostic.c (diagnostic_check_max_errors): New, broken out of ...
authorNathan Sidwell <nathan@acm.org>
Mon, 5 Dec 2016 12:24:39 +0000 (12:24 +0000)
committerNathan Sidwell <nathan@gcc.gnu.org>
Mon, 5 Dec 2016 12:24:39 +0000 (12:24 +0000)
commitd0ea9f0aa270f9791df42eb409e90c718575ad9a
tree63b942309e0e3faf9b2b19ff2be30494a2a4bbf1
parentfb5e7daea59060603a2e526cab4e35b32a8e9438
diagnostic.c (diagnostic_check_max_errors): New, broken out of ...

gcc/
* diagnostic.c (diagnostic_check_max_errors): New, broken out of ...
(diagnostic_action_after_output): ... here.
(diagnostic_report_diagnostic): Call it for non-notes.
* diagnostic.h (struct diagnostic_context): Make max_errors signed
int.
(diagnostic_check_max_errors): Declare.

gcc/fortran/
* error.c (gfc_warning_check): Call diagnostic_check_max_errors.
(gfc_error_check): Likewise.

gcc/testsuite/
* c-c++-common/fmax_errors.c: Check notes after last error are
emitted.

From-SVN: r243254
gcc/ChangeLog
gcc/diagnostic.c
gcc/diagnostic.h
gcc/fortran/ChangeLog
gcc/fortran/error.c
gcc/testsuite/ChangeLog
gcc/testsuite/c-c++-common/fmax-errors.c