ubuntu-buildroot/output/build/host-gcc-initial-11.4.0/gcc/testsuite/gnat.dg/opt79.adb

29 lines
362 B
Ada
Raw Permalink Normal View History

2024-04-01 15:19:46 +00:00
-- { dg-do compile }
-- { dg-options "-O" }
package body Opt79 is
function F (I : Integer) return Arr is
A : Arr;
procedure Nested is
procedure Inner is
begin
A (1) := 0;
end;
begin
Inner;
end;
begin
Nested;
for J in A'Range loop
A (J) := I;
end loop;
return A;
end;
end Opt79;