[Ada] Bug in Enum_Subtype'Image in Ada 2020 mode

gcc/ada/

	* exp_imgv.adb (Expand_Image_Attribute): Add Root_Type, so
	constrained subtypes work.
This commit is contained in:
Bob Duff 2020-06-18 09:10:33 -04:00 committed by Pierre-Marie de Rodat
parent f35bd40944
commit 116e8b669e
1 changed files with 1 additions and 1 deletions

View File

@ -483,7 +483,7 @@ package body Exp_Imgv is
-- underlying type.
if Ada_Version >= Ada_2020 then
Rtyp := Underlying_Type (Ptyp);
Rtyp := Underlying_Type (Root_Type (Ptyp));
else
Rtyp := Root_Type (Ptyp);
end if;