OSDN Git Service

gcc/ada/
[pf3gnuchains/gcc-fork.git] / gcc / testsuite / gnat.dg / in_mod_conv.adb
1 -- { dg-do compile }
2
3 procedure in_mod_conv is
4    package Test is 
5      type T  is new Natural range 1..6;
6      subtype T_SubType is T range 3..5;
7      type A1 is array (T range <>) of boolean;
8      type A2 is new A1 (T_SubType);
9      PRAGMA pack (A2);
10      type New_A2 is new A2; 
11   end Test;
12   package body Test is 
13      procedure P1 (Obj : in New_A2) is
14      begin   
15         null;   
16      end P1; 
17      procedure P2 (Data : in out A2) is
18      begin   
19         P1 (New_A2 (Data (T_SubType)));  -- test 
20      end P2; 
21   end Test;
22 begin   
23    null;   
24 end;