[Ada] Spurious warning about hiding in generic instantiation

gcc/ada/

	* sem_util.adb (Enter_Name): Suppress hiding warning when in an
	instance.
This commit is contained in:
Gary Dismukes 2021-08-11 18:41:28 -04:00 committed by Pierre-Marie de Rodat
parent 1c37d1960a
commit 302563cf1b

View file

@ -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)