ada: Fix internal error on call with parameter of predicated subtype
commita3626f49d64c8b81aadae61ae4fad7d4d0f9d6b8
authorEric Botcazou <ebotcazou@adacore.com>
Thu, 28 Sep 2023 13:53:36 +0000 (28 15:53 +0200)
committerMarc Poulhiès <poulhies@adacore.com>
Tue, 19 Dec 2023 14:27:51 +0000 (19 15:27 +0100)
tree86cc40e61a3f52f7f70d00cd9d349c1c1cdc385b
parent257a2fca4f9fdf2f506b6d5a63109fb38baacce3
ada: Fix internal error on call with parameter of predicated subtype

The problem is that the predicated subtype does not inherit all the required
attributes of a string subtype with a static predicate.

gcc/ada/

* sem_ch3.adb (Analyze_Subtype_Declaration): Remove a short-circuit
for subtypes without aspects when it comes to predicates.
* sem_util.adb (Inherit_Predicate_Flags): Deal with private subtypes
whose full view is an Itype.
gcc/ada/sem_ch3.adb
gcc/ada/sem_util.adb