aboutsummaryrefslogtreecommitdiffstats
path: root/gcc-4.9/gcc/testsuite/gnat.dg/specs/aggr4_pkg.ads
blob: c0f3c8c828adf87c5a72984eb4c90d1b72db4ddf (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
-- { dg-excess-errors "cannot generate code" }

package Aggr4_Pkg is

   function F return Integer;

   type Rec1 is tagged record
      I : Integer;
   end record;

   Zero : constant Rec1 := (I => F);

   type Enum is (One, Two);

   type Rec2 (D : Enum := One) is record
      case D is
         when One => Value : Rec1;
         when others => null;
      end case;
   end record;

   type Rec3 is record
      Data : Rec2;
   end record;

end Aggr4_Pkg;