c++: prvalue of array type [PR111286]
[official-gcc.git] / gcc / testsuite / gnat.dg / addr15.adb
blobbb79dff862f5c90e4e62af4e65d89ad8cccc722b
1 -- { dg-do run }
3 with System; use System;
5 procedure Addr15 is
7 function Get_Bound (Param : Integer) return Integer is (Param);
9 type Alpha_Typ is array (1 .. Get_Bound (1)) of Integer;
10 type Beta_Typ is array (1 .. Get_Bound (0)) of Integer;
12 Alpha : Alpha_Typ;
13 Beta : aliased Beta_Typ;
15 begin
16 if Alpha'Address = Beta'Address then
17 raise Program_Error;
18 end if;
19 end;