From: Hristian Kirtchev Date: Wed, 23 May 2018 10:22:30 +0000 (+0000) Subject: [Ada] Suppression of elaboration-related warnings X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=a0f3668cdee0255ce993f4309448329ca40bfe3c;p=gcc.git [Ada] Suppression of elaboration-related warnings This patch updates the documentation section on suppressing elaboration warnings. No change in behavior, no need for a test. 2018-05-23 Hristian Kirtchev gcc/ada/ * sem_elab.adb: Update the section on suppressing elaboration warnings. From-SVN: r260581 --- diff --git a/gcc/ada/ChangeLog b/gcc/ada/ChangeLog index cfe3b82cc66..31dca9e76c0 100644 --- a/gcc/ada/ChangeLog +++ b/gcc/ada/ChangeLog @@ -1,3 +1,7 @@ +2018-05-23 Hristian Kirtchev + + * sem_elab.adb: Update the section on suppressing elaboration warnings. + 2018-05-23 Hristian Kirtchev * einfo.adb (Is_Elaboration_Checks_OK_Id): Use predicate diff --git a/gcc/ada/sem_elab.adb b/gcc/ada/sem_elab.adb index 0ec49c10796..72d80f81663 100644 --- a/gcc/ada/sem_elab.adb +++ b/gcc/ada/sem_elab.adb @@ -394,33 +394,38 @@ package body Sem_Elab is -- suppressed. -- -- In addition to switch -gnatwL, pragma Warnings may be used to suppress - -- elaboration-related warnings by wrapping a construct in the following - -- manner: + -- elaboration-related warnings when used in the following manner: -- -- pragma Warnings ("L"); - -- - -- pragma Warnings ("l"); + -- + -- + -- + -- pragma Warnings (Off, target); + -- + -- pragma Warnings (Off); + -- -- -- * To suppress elaboration warnings for '[Unrestricted_]Access of -- entries, operators, and subprograms, either: -- - -- - Wrap the entry, operator, or subprogram, or - -- - Wrap the attribute, or + -- - Suppress the entry, operator, or subprogram, or + -- - Suppress the attribute, or -- - Use switch -gnatw.f -- -- * To suppress elaboration warnings for calls to entries, operators, -- and subprograms, either: -- - -- - Wrap the entry, operator, or subprogram, or - -- - Wrap the call + -- - Suppress the entry, operator, or subprogram, or + -- - Suppress the call -- - -- * To suppress elaboration warnings for instantiations, wrap the + -- * To suppress elaboration warnings for instantiations, suppress the -- instantiation. -- -- * To suppress elaboration warnings for task activations, either: -- - -- - Wrap the task object, or - -- - Wrap the task type + -- - Suppress the task object, or + -- - Suppress the task type, or + -- - Suppress the activation call -------------- -- Switches --