diff options
author | Gary Dismukes <dismukes@adacore.com> | 2021-08-11 18:41:28 -0400 |
---|---|---|
committer | Pierre-Marie de Rodat <derodat@adacore.com> | 2021-10-01 06:13:38 +0000 |
commit | 302563cf1ba92b0872341f5064260d6799e9e963 (patch) | |
tree | d2122d24de436cd2842b5486e198802ece8537fd | |
parent | 1c37d1960adf1c30fa700b89d588182c84f8f22d (diff) | |
download | gcc-302563cf1ba92b0872341f5064260d6799e9e963.zip gcc-302563cf1ba92b0872341f5064260d6799e9e963.tar.gz gcc-302563cf1ba92b0872341f5064260d6799e9e963.tar.bz2 |
[Ada] Spurious warning about hiding in generic instantiation
gcc/ada/
* sem_util.adb (Enter_Name): Suppress hiding warning when in an
instance.
-rw-r--r-- | gcc/ada/sem_util.adb | 4 |
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) |