Debian Codegraph @

gcc/testsuite/gnat.dg/opt55.adb

raw
1 -- { dg-do compile }
2 -- { dg-options "-O" }
3
4 package body Opt55 is
5
6 function Cond (B : Boolean; If_True, If_False : Date) return Date is
7 begin
8 if B then
9 return If_True;
10 else
11 return If_False;
12 end if;
13 end;
14
15 function F (C : Rec2; B : Boolean) return Date is
16 begin
17 return Cond (B, C.D1, C.D2);
18 end;
19
20 end Opt55;