[Ada] Fix crash on array component with Default_Value
Pierre-Marie de Rodat
derodat@adacore.com
Mon Oct 11 13:39:03 GMT 2021
When complaining about a compile-time constraint error within a default
initialization procedure we assumed that this procedure initializes a
record object. However, it can initialize an array object too.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* exp_util.adb (Inside_Init_Proc): Simplify.
* sem_aggr.adb (Resolve_Record_Aggregate): Fix style.
* sem_util.adb (Compile_Time_Constraint_Error): Guard against
calling Corresponding_Concurrent_Type with an array type entity.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: patch.diff
Type: text/x-diff
Size: 2128 bytes
Desc: not available
URL: <https://gcc.gnu.org/pipermail/gcc-patches/attachments/20211011/1a3e7c51/attachment.bin>
More information about the Gcc-patches
mailing list