2003-12-26 Guilhem Lavaux <guilhem@kaffe.org>
[official-gcc.git] / gcc / testsuite / ada / acats / support / fa11c00.a
blob4b153b25ebae641be8c3424080ec3130f168b88b
1 -- FA11C00.A
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.
16 -- DISCLAIMER
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 --*
26 -- FOUNDATION DESCRIPTION:
27 -- This foundation declares parent types and operations that can
28 -- be inherited by its children.
30 -- CHANGE HISTORY:
31 -- 06 Dec 94 SAIC ACVC 2.0
33 --!
35 package FA11C00_0 is -- Package Animal
37 type Kilogram_Weight_Type is new Natural;
38 subtype Species_Name_Type is String (1 .. 20);
40 type Animal is tagged
41 record
42 Common_Name : Species_Name_Type;
43 Weight : Kilogram_Weight_Type;
44 end record;
46 function Image (A : Animal) return String;
48 end FA11C00_0; -- Package Animal
50 --=================================================================--
52 package body FA11C00_0 is -- Package body Animal
54 function Image (A : Animal) return String is
55 begin
56 return ("Animal Species: " & A.Common_Name);
57 end Image;
59 end FA11C00_0; -- Package body Animal
61 --=================================================================--
63 package FA11C00_0.FA11C00_1 is -- Package Animal.Mammal
65 type Hair_Color_Type is (Black, Brown, Blonde, Grey, White, Red);
67 type Mammal is new Animal with
68 record
69 Hair_Color : Hair_Color_Type;
70 end record;
72 function Image (M : Mammal) return String;
74 end FA11C00_0.FA11C00_1; -- Package Animal.Mammal
76 --=================================================================--
78 package body FA11C00_0.FA11C00_1 is -- Package body Animal.Mammal
80 function Image (M : Mammal) return String is
81 begin
82 return ("Mammal Species: " & M.Common_Name);
83 end Image;
85 end FA11C00_0.FA11C00_1; -- Package body Animal.Mammal
87 --=================================================================--
89 package FA11C00_0.FA11C00_1.FA11C00_2 is -- Package Animal.Mammal.Primate
91 type Habitat_Type is (Arboreal, Terrestrial);
93 type Primate is new Mammal with
94 record
95 Habitat : Habitat_Type;
96 end record;
98 function Image (P : Primate) return String;
100 end FA11C00_0.FA11C00_1.FA11C00_2; -- Package Animal.Mammal.Primate
102 --=================================================================--
104 -- Package body Animal.Mammal.Primate
105 package body FA11C00_0.FA11C00_1.FA11C00_2 is
107 function Image (P : Primate) return String is
108 begin
109 return ("Primate Species: " & P.Common_Name);
110 end Image;
112 end FA11C00_0.FA11C00_1.FA11C00_2; -- Package body Animal.Mammal.Primate