From 6f934861c1eb93234e63483e04975bf0cd612da7 Mon Sep 17 00:00:00 2001 From: Arnaud Charlet Date: Wed, 18 Sep 2019 08:31:51 +0000 Subject: [PATCH] [Ada] Improve doc on Warning_As_Error 2019-09-18 Arnaud Charlet gcc/ada/ * doc/gnat_rm/implementation_defined_pragmas.rst: Improve doc on Warning_As_Error. * gnat_rm.texi: Regenerate. From-SVN: r275842 --- gcc/ada/ChangeLog | 6 ++++++ gcc/ada/doc/gnat_rm/implementation_defined_pragmas.rst | 6 ++++-- gcc/ada/gnat_rm.texi | 6 ++++-- 3 files changed, 14 insertions(+), 4 deletions(-) diff --git a/gcc/ada/ChangeLog b/gcc/ada/ChangeLog index 07221d3cb0d..77089ccf1f7 100644 --- a/gcc/ada/ChangeLog +++ b/gcc/ada/ChangeLog @@ -1,3 +1,9 @@ +2019-09-18 Arnaud Charlet + + * doc/gnat_rm/implementation_defined_pragmas.rst: Improve doc on + Warning_As_Error. + * gnat_rm.texi: Regenerate. + 2019-09-18 Arnaud Charlet * doc/gnat_rm/implementation_defined_characteristics.rst, diff --git a/gcc/ada/doc/gnat_rm/implementation_defined_pragmas.rst b/gcc/ada/doc/gnat_rm/implementation_defined_pragmas.rst index 551401f7094..8ce22f1c04d 100644 --- a/gcc/ada/doc/gnat_rm/implementation_defined_pragmas.rst +++ b/gcc/ada/doc/gnat_rm/implementation_defined_pragmas.rst @@ -7489,9 +7489,11 @@ message string (it is not necessary to put an asterisk at the start and the end of the message, since this is implied). Another possibility for the static_string_EXPRESSION which works whether -or not error tags are enabled (*-gnatw.d*) is to use the +or not error tags are enabled (*-gnatw.d*) is to use a single *-gnatw* tag string, enclosed in brackets, -as shown in the example below, to treat a class of warnings as errors. +as shown in the example below, to treat one category of warnings as errors. +Note that if you want to treat multiple categories of warnings as errors, +you can use multiple pragma Warning_As_Error. The above use of patterns to match the message applies only to warning messages generated by the front end. This pragma can also be applied to diff --git a/gcc/ada/gnat_rm.texi b/gcc/ada/gnat_rm.texi index 921dd1664f2..1f5616fe393 100644 --- a/gcc/ada/gnat_rm.texi +++ b/gcc/ada/gnat_rm.texi @@ -8994,9 +8994,11 @@ message string (it is not necessary to put an asterisk at the start and the end of the message, since this is implied). Another possibility for the static_string_EXPRESSION which works whether -or not error tags are enabled (@emph{-gnatw.d}) is to use the +or not error tags are enabled (@emph{-gnatw.d}) is to use a single @emph{-gnatw} tag string, enclosed in brackets, -as shown in the example below, to treat a class of warnings as errors. +as shown in the example below, to treat one category of warnings as errors. +Note that if you want to treat multiple categories of warnings as errors, +you can use multiple pragma Warning_As_Error. The above use of patterns to match the message applies only to warning messages generated by the front end. This pragma can also be applied to -- 2.30.2