Require target lra in gcc.dg/pr108095.c
[official-gcc.git] / gcc / testsuite / gnat.dg / expr_func9.adb
blob4bfa21dc647eb37eecf035fff0e99e1c65d8795c
1 -- { dg-do compile }
2 -- { dg-options "-gnatws" }
4 procedure Expr_Func9 is
6 type Root is interface;
8 type Child1 is new Root with null record;
10 type Child2 is new Root with record
11 I2 : Integer;
12 end record;
14 function Create (I : Integer) return Child2 is (I2 => I);
16 I : Root'Class :=
17 (if False
18 then Child1'(null record)
19 else
20 Create (1));
22 begin
23 null;
24 end Expr_Func9;