https://gcc.gnu.org/bugzilla/show_bug.cgi?id=116190
--- Comment #2 from aj at ianozi dot com ---
Apologies, I misspoke. I tested it with "My_Array" being a named type, I
didn't test it with "This_Crashes" being a named type, ergo this crashes:
with Ada.Strings.Unbounded; use Ada.Strings.Unbounded;
procedure P is
type Arr is array (1..5) of Unbounded_String;
My_Array : Arr := [others => To_Unbounded_String ("Test")];
This_Crashes : constant array (Natural range <>) of Unbounded_String := [for
I of My_Array => I];
begin
null;
end P;
But this does not:
with Ada.Strings.Unbounded; use Ada.Strings.Unbounded;
procedure P is
type Arr is array (1..5) of Unbounded_String;
My_Array : Arr := [others => To_Unbounded_String ("Test")];
This_Crashes : constant Arr := [for I of My_Array => I];
begin
null;
end P;
Which probably wasn't as helpful...