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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [gnat.dg/] [interface3.adb] - Blame information for rev 774

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 696 jeremybenn
--  { dg-do run }
2
 
3
procedure interface3 is
4
-- 
5
   package Pkg is
6
      type Foo is interface;
7
      subtype Element_Type is Foo'Class;
8
--    
9
      type Element_Access  is access Element_Type;
10
      type Elements_Type   is array (1 .. 1) of Element_Access;
11
      type Elements_Access is access Elements_Type;
12
--    
13
      type Vector is tagged record
14
         Elements : Elements_Access;
15
      end record;
16
--    
17
      procedure Test (Obj : Vector);
18
   end;
19
-- 
20
   package body Pkg is
21
      procedure Test (Obj : Vector) is
22
         Elements : Elements_Access := new Elements_Type;
23
--    
24
      begin
25
         Elements (1) := new Element_Type'(Obj.Elements (1).all);
26
      end;
27
   end;
28
--
29
begin
30
   null;
31
end;

powered by: WebSVN 2.1.0

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