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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [gnat.dg/] [unchecked_convert4.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 compile }
2
 
3
with Unchecked_Conversion;
4
 
5
procedure Unchecked_Convert4 is
6
 
7
  type Uint32 is mod 2**32;
8
 
9
  type Rec is record
10
    I : Uint32;
11
  end record;
12
  for Rec'Size use 32;
13
  pragma Atomic (Rec);
14
 
15
  function Conv is new Unchecked_Conversion (Uint32, Rec);
16
 
17
  function F return Uint32;
18
  pragma Import (Ada, F);
19
 
20
  procedure Proc (R : Rec) is begin null; end;
21
 
22
begin
23
  Proc (Conv (F or 1));
24
end;

powered by: WebSVN 2.1.0

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