OpenCores
URL https://opencores.org/ocsvn/openrisc_me/openrisc_me/trunk

Subversion Repositories openrisc_me

[/] [openrisc/] [trunk/] [gnu-src/] [gcc-4.5.1/] [gcc/] [testsuite/] [gnat.dg/] [lhs_view_convert.adb] - Rev 304

Compare with Previous | Blame | View Log

-- { dg-do run }
-- { dg-options "-gnatp" }
 
procedure Lhs_View_Convert is
 
   type Root is tagged record
      RV : Natural;
   end record;
 
   type Derived is new Root with null record;
 
   Root_Instance : Root := (RV => 1);
 
   Derived_Instance : Derived;
 
   procedure Process is
      X : Natural := Derived_Instance.RV;
   begin
      null;
   end;
begin
   Derived_Instance.RV := 2;
 
   Root (Derived_Instance) := Root (Root_Instance);
 
   if Derived_Instance.RV /= Root_Instance.RV then
      raise Program_Error;
   end if;
end;
 

Compare with Previous | Blame | View Log

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.