aboutsummaryrefslogtreecommitdiff
path: root/gcc/ada/sem.adb
diff options
context:
space:
mode:
authorRobert Dewar <dewar@adacore.com>2007-12-13 11:19:43 +0100
committerArnaud Charlet <charlet@gcc.gnu.org>2007-12-13 11:19:43 +0100
commit561b58498765f443cf6905b7ee246af5a1a0f626 (patch)
tree1eff0c4702214edde615103bf7be7c328fafe364 /gcc/ada/sem.adb
parent0312b364242bc5d1f96d00d7228ede4a26730e0c (diff)
downloadgcc-561b58498765f443cf6905b7ee246af5a1a0f626.zip
gcc-561b58498765f443cf6905b7ee246af5a1a0f626.tar.gz
gcc-561b58498765f443cf6905b7ee246af5a1a0f626.tar.bz2
sem_ch5.adb, [...]: Update handling of assigned value/unreferenced warnings
2007-12-06 Robert Dewar <dewar@adacore.com> * sem_ch5.adb, s-taskin.adb, a-ciorma.adb, a-coorma.adb, a-cohama.adb, a-cihama.adb, g-awk.adb, s-inmaop-posix.adb: Update handling of assigned value/unreferenced warnings * exp_smem.adb: Update handling of assigned value/unreferenced warnings * sem.adb: Update handling of assigned value/unreferenced warnings * a-exexpr-gcc.adb: Add a pragma warnings off for boolean return * lib-xref.ads: Improve documentation for k xref type * lib-xref.adb: Update handling of assigned value/unreferenced warnings (Generate_Reference): Warning for reference to entity for which a pragma Unreferenced has been given should be unconditional. If the entity is a discriminal, mark the original discriminant as referenced. * sem_warn.ads, sem_warn.adb (Check_One_Unit): Test Renamed_In_Spec to control giving warning for no entities referenced in package (Check_One_Unit): Don't give message about no entities referenced in a package if a pragma Unreferenced has appeared. Handle new warning flag -gnatw.a/-gnatw.A Update handling of assigned value/unreferenced warnings * atree.h: Add flags up to Flag247 (Flag231): New macro. From-SVN: r130815
Diffstat (limited to 'gcc/ada/sem.adb')
-rw-r--r--gcc/ada/sem.adb7
1 files changed, 4 insertions, 3 deletions
diff --git a/gcc/ada/sem.adb b/gcc/ada/sem.adb
index 7dab134..7fcf2dd 100644
--- a/gcc/ada/sem.adb
+++ b/gcc/ada/sem.adb
@@ -727,6 +727,7 @@ package body Sem is
To : Entity_Id)
is
Found : Boolean;
+ pragma Warnings (Off, Found);
procedure Search_Stack
(Top : Suppress_Stack_Entry_Ptr;
@@ -1282,10 +1283,10 @@ package body Sem is
S_Sem_Unit : constant Unit_Number_Type := Current_Sem_Unit;
S_GNAT_Mode : constant Boolean := GNAT_Mode;
S_Discard_Names : constant Boolean := Global_Discard_Names;
- Generic_Main : constant Boolean :=
- Nkind (Unit (Cunit (Main_Unit)))
- in N_Generic_Declaration;
+ Generic_Main : constant Boolean :=
+ Nkind (Unit (Cunit (Main_Unit)))
+ in N_Generic_Declaration;
-- If the main unit is generic, every compiled unit, including its
-- context, is compiled with expansion disabled.