summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gnat.dg/generic_disp_pkg.ads
blob: 5be54921d83325ff5dec3179a66f6c6329072ff7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
with Ada.Tags.Generic_Dispatching_Constructor;

package Generic_Disp_Pkg is
   type Iface is interface;
   function Constructor (I : not null access Integer) return Iface is abstract;
   function Dispatching_Constructor
      is new Ada.Tags.Generic_Dispatching_Constructor
               (T           => Iface,
                Parameters  => Integer,
                Constructor => Constructor);
   type DT is new Iface with null record; 
   overriding
   function Constructor (I : not null access Integer) return DT;
end Generic_Disp_Pkg;