view gcc/testsuite/gnat.dg/kill_value.adb @ 145:1830386684a0

gcc-9.2.0
author anatofuz
date Thu, 13 Feb 2020 11:34:05 +0900
parents 04ced10e8804
children
line wrap: on
line source

-- { dg-do run }

procedure kill_value is
   type Struct;
   type Pstruct is access all Struct;
   
   type Struct is record Next : Pstruct; end record;
   
   Vap : Pstruct := new Struct;

begin
   for J in 1 .. 10 loop
      if Vap /= null then
         while Vap /= null
         loop
            Vap := Vap.Next;
         end loop;
      end if;
   end loop;
end;