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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-old/] [gcc-4.2.2/] [gcc/] [testsuite/] [ada/] [acats/] [tests/] [c7/] [c74207b.ada] - Blame information for rev 149

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

Line No. Rev Author Line
1 149 jeremybenn
-- C74207B.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
-- CHECK THAT 'CONSTRAINED CAN BE APPLIED AFTER THE FULL DECLARATION OF
26
-- A PRIVATE TYPE THAT IS DERIVED FROM A PRIVATE TYPE.
27
 
28
-- BHS 6/18/84
29
 
30
WITH REPORT;
31
USE REPORT;
32
PROCEDURE C74207B IS
33
BEGIN
34
     TEST ("C74207B", "AFTER THE FULL DECLARATION OF A PRIVATE " &
35
                      "TYPE DERIVED FROM A PRIVATE TYPE, " &
36
                      "'CONSTRAINED MAY BE APPLIED");
37
 
38
     DECLARE
39
          PACKAGE P1 IS
40
               TYPE PREC (D : INTEGER) IS PRIVATE;
41
               TYPE P IS PRIVATE;
42
          PRIVATE
43
               TYPE PREC (D : INTEGER) IS RECORD
44
                         NULL;
45
                    END RECORD;
46
               TYPE P IS NEW INTEGER;
47
          END P1;
48
 
49
          PACKAGE P2 IS
50
               TYPE LP1 IS LIMITED PRIVATE;
51
               TYPE LP2 IS LIMITED PRIVATE;
52
          PRIVATE
53
               TYPE LP1 IS NEW P1.PREC(3);
54
               TYPE LP2 IS NEW P1.P;
55
               B1 : BOOLEAN := LP1'CONSTRAINED;
56
               B2 : BOOLEAN := LP2'CONSTRAINED;
57
          END P2;
58
 
59
          PACKAGE BODY P2 IS
60
          BEGIN
61
               IF NOT IDENT_BOOL(B1) THEN
62
                    FAILED ("WRONG VALUE FOR LP1'CONSTRAINED");
63
               END IF;
64
               IF NOT IDENT_BOOL(B2) THEN
65
                    FAILED ("WRONG VALUE FOR LP2'CONSTRAINED");
66
               END IF;
67
          END P2;
68
 
69
     BEGIN
70
          NULL;
71
     END;
72
 
73
     RESULT;
74
 
75
END C74207B;

powered by: WebSVN 2.1.0

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