aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--gcc/ada/sem_util.adb4
1 files changed, 4 insertions, 0 deletions
diff --git a/gcc/ada/sem_util.adb b/gcc/ada/sem_util.adb
index 98e68779..0c0d34b 100644
--- a/gcc/ada/sem_util.adb
+++ b/gcc/ada/sem_util.adb
@@ -8656,6 +8656,10 @@ package body Sem_Util is
and then Comes_From_Source (C)
and then Comes_From_Source (Def_Id)
+ -- Don't warn within a generic instantiation
+
+ and then not In_Instance
+
-- Don't warn unless entity in question is in extended main source
and then In_Extended_Main_Source_Unit (Def_Id)