aboutsummaryrefslogtreecommitdiffstats
path: root/gcc-4.9/gcc/testsuite/gnat.dg/self1.adb
blob: dc6f485b8febafb8cfedcfcc106b29a9f8e8a2bf (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
--  { dg-do compile }

procedure Self1 is      
   type Event;
        
   type Link (E : access Event) is limited record
      Val : Integer;
   end record;

   type Ptr is access all Event;
   
   type Event is tagged limited record
      Inner : Link (Event'access);
      Size  : Integer;
   end record;              
        
   Obj2 : Ptr := new Event'(Inner => (Event'access, 15),
                            Size => Link'size);
begin
   null;                    
end;