1--  { dg-do compile }
2--  { dg-options "-gnatws" }
3
4procedure aggr4 is
5   type Byte is range 0 .. 2**8 - 1;
6   for Byte'Size use 8;
7
8   type Time is array (1 .. 3) of Byte;
9
10   type UTC_Time is record
11      Values : Time;
12   end record;
13
14   type Local_Time is record
15      Values : Time;
16   end record;
17   for Local_Time use record
18      Values at 0 range 1 .. 24;
19   end record;
20
21   LOC : Local_Time;
22   UTC : UTC_Time;
23
24begin
25   UTC.Values := LOC.Values;
26   UTC := (Values => LOC.Values);
27end;
28