aboutsummaryrefslogtreecommitdiff
path: root/gcc/fold-const.cc
diff options
context:
space:
mode:
authorEric Botcazou <ebotcazou@adacore.com>2022-12-05 22:31:50 +0100
committerMarc Poulhiès <poulhies@adacore.com>2023-01-03 10:29:52 +0100
commite1e2b0070302169fbf3f3fd95a13ec819e71e2a5 (patch)
tree673a5901734022780dec8ae59d78801f889968aa /gcc/fold-const.cc
parentfee53a3194c0d8b747486b23980f1214cc1355b9 (diff)
downloadgcc-e1e2b0070302169fbf3f3fd95a13ec819e71e2a5.zip
gcc-e1e2b0070302169fbf3f3fd95a13ec819e71e2a5.tar.gz
gcc-e1e2b0070302169fbf3f3fd95a13ec819e71e2a5.tar.bz2
ada: Fix support of Default_Component_Value aspect on derived types
The support of the Default_Component_Value aspect on derived constrained array types is broken because of a couple of issues: 1) the derived types incorrectly inherit the initialization procedure of the ancestor types and 2) the propagation of the aspect does not work for constrained array types (unlike for unconstrained array types). gcc/ada/ * exp_tss.adb (Base_Init_Proc): Do not return the Init_Proc of the ancestor type for a derived array type. * sem_ch13.adb (Inherit_Aspects_At_Freeze_Point): Factor out the common processing done on representation items. For Default_Component_Value and Default_Value, look into the first subtype to find out the representation items.
Diffstat (limited to 'gcc/fold-const.cc')
0 files changed, 0 insertions, 0 deletions