aboutsummaryrefslogtreecommitdiff
path: root/gcc/ada/gcc-interface/decl.cc
diff options
context:
space:
mode:
authorSteve Baird <baird@adacore.com>2024-10-30 16:20:51 -0700
committerMarc Poulhiès <dkm@gcc.gnu.org>2024-11-14 14:54:31 +0100
commit29112f5e1b2a8751349943f72c046e7ad3c8de8e (patch)
treef5e80e0914c7c1c410d3bdba56d768834fe3eabe /gcc/ada/gcc-interface/decl.cc
parent35d36903dc616059ad0b34b1057a3037ab758597 (diff)
downloadgcc-29112f5e1b2a8751349943f72c046e7ad3c8de8e.zip
gcc-29112f5e1b2a8751349943f72c046e7ad3c8de8e.tar.gz
gcc-29112f5e1b2a8751349943f72c046e7ad3c8de8e.tar.bz2
ada: Improved legality checking for deep delta aggregates.
Enforce deep delta legality rules about nonoverlapping choices. For example, do not allow both Aaa.Bbb and Aaa.Bbb.Ccc as choices in one delta aggregate. One special case impacts "regular" Ada2022 delta aggregates - the rule preventing a record component from occurring twice as a choice in a delta aggregate was previously not being enforced. gcc/ada/ChangeLog: * sem_aggr.adb (Resolve_Delta_Aggregate): The rule about discriminant dependent component references in choices applies to both array and record delta aggregates, so check for violations in Resolve_Delta_Aggregate. Call a new procedure, Check_For_Bad_Dd_Component_Choice, for each choice. (Resolve_Delta_Record_Aggregate): Call a new procedure, Check_For_Bad_Overlap, for each pair of choices.
Diffstat (limited to 'gcc/ada/gcc-interface/decl.cc')
0 files changed, 0 insertions, 0 deletions