--  Arrays of static bounds compare unequal when their lengths differ (RM 4.5.2(23),
--  C45264C), and a positional aggregate without `others` has its own bounds, from the index
--  subtype's first (RM 4.3.3(26), CC3234A); assigned, its length is checked.
with Ada.Text_IO; use Ada.Text_IO;
procedure Main is
   subtype Int is Integer range 1 .. 10;
   type A1 is array (Int range <>) of Integer;
   type A2 is array (Int range <>, Int range <>) of Integer;
   type Ten is array (1 .. 10) of Integer;
   X : constant A1 (1 .. 5) := (1 .. 5 => 1);
   Y : constant A1 (1 .. 7) := (1 .. 7 => 1);
   P : constant A2 (1 .. 2, 1 .. 3) := (1 .. 2 => (1 .. 3 => 1));
   Q : constant A2 (1 .. 3, 1 .. 2) := (1 .. 3 => (1 .. 2 => 1));
   T : Ten := (others => 1);
begin
   Put_Line (Boolean'Image (X = Y) & Boolean'Image (X /= Y) & Boolean'Image (P = Q)
             & Boolean'Image (T (1 .. 5) = (1, 1, 1, 1, 1)) & Boolean'Image (T (6 .. 10) /= (1, 1, 1, 1, 1)));
   T := (1, 2, 3);
   Put_Line (Integer'Image (T (1)));
end Main;
