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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [ada/] [acats/] [tests/] [a/] [a74106c.ada] - Blame information for rev 720

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 720 jeremybenn
-- A74106C.ADA
2
 
3
--                             Grant of Unlimited Rights
4
--
5
--     Under contracts F33600-87-D-0337, F33600-84-D-0280, MDA903-79-C-0687,
6
--     F08630-91-C-0015, and DCA100-97-D-0025, the U.S. Government obtained 
7
--     unlimited rights in the software and documentation contained herein.
8
--     Unlimited rights are defined in DFAR 252.227-7013(a)(19).  By making 
9
--     this public release, the Government intends to confer upon all 
10
--     recipients unlimited rights  equal to those held by the Government.  
11
--     These rights include rights to use, duplicate, release or disclose the 
12
--     released technical data and computer software in whole or in part, in 
13
--     any manner and for any purpose whatsoever, and to have or permit others 
14
--     to do so.
15
--
16
--                                    DISCLAIMER
17
--
18
--     ALL MATERIALS OR INFORMATION HEREIN RELEASED, MADE AVAILABLE OR
19
--     DISCLOSED ARE AS IS.  THE GOVERNMENT MAKES NO EXPRESS OR IMPLIED 
20
--     WARRANTY AS TO ANY MATTER WHATSOEVER, INCLUDING THE CONDITIONS OF THE
21
--     SOFTWARE, DOCUMENTATION OR OTHER INFORMATION RELEASED, MADE AVAILABLE 
22
--     OR DISCLOSED, OR THE OWNERSHIP, MERCHANTABILITY, OR FITNESS FOR A
23
--     PARTICULAR PURPOSE OF SAID MATERIAL.
24
--*
25
-- OBJECTIVE:
26
--     CHECK THAT A FULL DECLARATION FOR A PRIVATE TYPE OR FOR A LIMITED
27
--     PRIVATE TYPE CAN BE GIVEN IN TERMS OF ANY SCALAR TYPE, ARRAY
28
--     TYPE, RECORD TYPE (WITH OR WITHOUT DISCRIMINANTS), ACCESS TYPE
29
--     (WITH OR WITHOUT DISCRIMINANTS), OR ANY TYPE DERIVED FROM ANY
30
--     OF THE ABOVE.
31
 
32
--     PART C: TYPES INVOLVING FIXED-POINT DATA.
33
 
34
-- HISTORY:
35
--     RM  05/11/81 CREATED ORIGINAL TEST.
36
--     DHH 10/15/87 CORRECTED RANGE ERRORS.
37
 
38
 
39
WITH REPORT;
40
PROCEDURE  A74106C  IS
41
 
42
     USE  REPORT;
43
 
44
BEGIN
45
 
46
     TEST( "A74106C" , "CHECK THAT PRIVATE TYPES AND LIMITED PRIVATE" &
47
                       " TYPES CAN BE DEFINED IN TERMS OF" &
48
                       " FIXED-POINT TYPES" );
49
 
50
     DECLARE
51
 
52
          PACKAGE  P0  IS
53
               TYPE  F0  IS  PRIVATE;
54
          PRIVATE
55
               TYPE  F0  IS  DELTA 1.0  RANGE 0.0 .. 10.0;
56
          END  P0;
57
 
58
          PACKAGE  P1  IS
59
               USE   P0;
60
               TYPE  FX  IS  DELTA 0.1  RANGE 0.0 .. 1.0;
61
               TYPE  F1  IS  PRIVATE;
62
               TYPE  F2  IS  PRIVATE;
63
               TYPE  F3  IS  PRIVATE;
64
               TYPE  F4  IS  PRIVATE;
65
               TYPE  F5  IS  PRIVATE;
66
               TYPE  F6  IS  PRIVATE;
67
               TYPE  F7  IS  PRIVATE;
68
               TYPE  F8  IS  PRIVATE;
69
               TYPE  F9  IS  PRIVATE;
70
               TYPE  FA  IS  PRIVATE;
71
               TYPE  FB  IS  PRIVATE;
72
               TYPE  FC  IS  PRIVATE;
73
               TYPE  NF  IS  DELTA 0.1 RANGE 1.0 .. 2.0;
74
               TYPE  ARR_F             IS  ARRAY(1..2) OF FX;
75
               TYPE  ACC_F             IS  ACCESS FX;
76
               TYPE  REC_F             IS  RECORD F : FX; END RECORD;
77
               TYPE  D_REC_F(I : INTEGER := 1) IS
78
                    RECORD F : FX; END RECORD;
79
          PRIVATE
80
               TYPE  FC  IS  NEW  F0;
81
               TYPE  F1  IS  DELTA 100.0  RANGE -100.0 .. 900.0;
82
               TYPE  F2  IS  NEW  FX  RANGE 0.0 .. 0.5;
83
               TYPE  F3  IS  NEW  NF;
84
               TYPE  F4  IS  ARRAY(1..2) OF FX;
85
               TYPE  F5  IS  NEW ARR_F;
86
               TYPE  F6  IS  ACCESS FX;
87
               TYPE  F7  IS  NEW ACC_F;
88
               TYPE  F8  IS  RECORD F : FX; END RECORD;
89
               TYPE  F9  IS  NEW REC_F;
90
               TYPE  FA  IS  ACCESS D_REC_F;
91
               TYPE  FB  IS  ACCESS D_REC_F;
92
          END  P1;
93
 
94
     BEGIN
95
 
96
          NULL;
97
 
98
     END;
99
 
100
 
101
     DECLARE
102
 
103
          PACKAGE  P0  IS
104
               TYPE  F0  IS  LIMITED PRIVATE;
105
          PRIVATE
106
               TYPE  F0  IS  DELTA 1.0  RANGE 0.0 .. 10.0;
107
          END  P0;
108
 
109
          PACKAGE  P1  IS
110
               USE   P0;
111
               TYPE  FX  IS  DELTA 0.1  RANGE 0.0 .. 1.0;
112
               TYPE  F1  IS  LIMITED PRIVATE;
113
               TYPE  F2  IS  LIMITED PRIVATE;
114
               TYPE  F3  IS  LIMITED PRIVATE;
115
               TYPE  F4  IS  LIMITED PRIVATE;
116
               TYPE  F5  IS  LIMITED PRIVATE;
117
               TYPE  F6  IS  LIMITED PRIVATE;
118
               TYPE  F7  IS  LIMITED PRIVATE;
119
               TYPE  F8  IS  LIMITED PRIVATE;
120
               TYPE  F9  IS  LIMITED PRIVATE;
121
               TYPE  FA  IS  LIMITED PRIVATE;
122
               TYPE  FB  IS  LIMITED PRIVATE;
123
               TYPE  FC  IS  LIMITED PRIVATE;
124
               TYPE  NF  IS  DELTA 0.1 RANGE 1.0 .. 2.0;
125
               TYPE  ARR_F                 IS  ARRAY(1..2) OF FX;
126
               TYPE  ACC_F                 IS  ACCESS FX;
127
               TYPE  REC_F                 IS RECORD F : FX; END RECORD;
128
               TYPE  D_REC_F(I : INTEGER := 1) IS
129
                    RECORD F : FX; END RECORD;
130
          PRIVATE
131
               TYPE  FC  IS  NEW  F0;
132
               TYPE  F1  IS  DELTA 100.0  RANGE -100.0 .. 900.0;
133
               TYPE  F2  IS  NEW  FX  RANGE 0.0 .. 0.5;
134
               TYPE  F3  IS  NEW  NF;
135
               TYPE  F4  IS  ARRAY(1..2) OF FX;
136
               TYPE  F5  IS  NEW ARR_F;
137
               TYPE  F6  IS  ACCESS FX;
138
               TYPE  F7  IS  NEW ACC_F;
139
               TYPE  F8  IS  RECORD F : FX; END RECORD;
140
               TYPE  F9  IS  NEW REC_F;
141
               TYPE  FA  IS  ACCESS D_REC_F;
142
               TYPE  FB  IS  ACCESS D_REC_F;
143
          END  P1;
144
 
145
     BEGIN
146
 
147
          NULL;
148
 
149
     END;
150
 
151
 
152
     RESULT;
153
 
154
 
155
END A74106C;

powered by: WebSVN 2.1.0

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