aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/gnat.dg/opt90b.adb
blob: 6da58bbcc7eafceb39a13b15200ddd89e2a837f7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
-- { dg-do run }
-- { dg-options "-O2" }

with Ada.Calendar; use Ada.Calendar;
with Opt90b_Pkg; use Opt90b_Pkg;

procedure Opt90b is
  B : constant Integer := Year (Clock);
  V : Data;

begin
  V := (R => (A => 0, B => B, C => 0, D => "000000000000"));
  if V.R.B /= B then
    raise Program_Error;
  end if;
end;