From: Piotr Trojanek Date: Sun, 10 May 2020 19:12:33 +0000 (+0200) Subject: [Ada] Fix expansion of delta aggregates with slices X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=c78efe921c1fab590293476ae9910e1bb5b090c4;p=gcc.git [Ada] Fix expansion of delta aggregates with slices gcc/ada/ * exp_aggr.adb (Expand_N_Delta_Aggregate): Use type of the delta base expression for the anonymous object of the delta aggregate. --- diff --git a/gcc/ada/exp_aggr.adb b/gcc/ada/exp_aggr.adb index 6832d401eb6..884c0ee434b 100644 --- a/gcc/ada/exp_aggr.adb +++ b/gcc/ada/exp_aggr.adb @@ -6845,7 +6845,7 @@ package body Exp_Aggr is procedure Expand_N_Delta_Aggregate (N : Node_Id) is Loc : constant Source_Ptr := Sloc (N); - Typ : constant Entity_Id := Etype (N); + Typ : constant Entity_Id := Etype (Expression (N)); Decl : Node_Id; begin