]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
ada: Fix bogus error for delta aggregate as expression function
authorEric Botcazou <ebotcazou@adacore.com>
Mon, 28 Oct 2024 08:30:07 +0000 (09:30 +0100)
committerMarc Poulhiès <dkm@gcc.gnu.org>
Tue, 12 Nov 2024 13:00:52 +0000 (14:00 +0100)
The compiler correctly accepts the other forms of aggregates.

gcc/ada/ChangeLog:

PR ada/113868
* par-ch6.adb (P_Subprogram) <Scan_Body_Or_Expression_Function>:
Add delta aggregate alongside the other forms of aggregates.

gcc/ada/par-ch6.adb

index 7fe4337353518d8cf5ef6e0782ff6b11db9b4efc..c3cc57256164bd404150740d2d9bce3fe2b23ab8 100644 (file)
@@ -884,6 +884,7 @@ package body Ch6 is
 
                      if not (Paren_Count (Expr) /= 0
                               or else Nkind (Expr) in N_Aggregate
+                                                    | N_Delta_Aggregate
                                                     | N_Extension_Aggregate
                                                     | N_Quantified_Expression)
                      then