From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Thread: 103376,86f72a7c465f6eb3 X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII Path: g2news1.google.com!postnews.google.com!g14g2000cwa.googlegroups.com!not-for-mail From: "Andrew" Newsgroups: comp.lang.ada Subject: Re: seperate compilation for protected objects Date: 1 Apr 2005 00:25:27 -0800 Organization: http://groups.google.com Message-ID: <1112343927.274041.27730@g14g2000cwa.googlegroups.com> References: <1112270905.678889.118410@f14g2000cwb.googlegroups.com> <5sug2d.qmp.ln@hunter.axlog.fr> NNTP-Posting-Host: 4.228.123.19 Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable X-Trace: posting.google.com 1112343956 32583 127.0.0.1 (1 Apr 2005 08:25:56 GMT) X-Complaints-To: groups-abuse@google.com NNTP-Posting-Date: Fri, 1 Apr 2005 08:25:56 +0000 (UTC) In-Reply-To: <5sug2d.qmp.ln@hunter.axlog.fr> User-Agent: G2/0.2 Complaints-To: groups-abuse@google.com Injection-Info: g14g2000cwa.googlegroups.com; posting-host=4.228.123.19; posting-account=Kq9unQ0AAADh_grEViI3JGqegXKDDjxt Xref: g2news1.google.com comp.lang.ada:10207 Date: 2005-04-01T00:25:27-08:00 List-Id: Thanks Jean-Pierre. The problem was that I spelled separate wrong. Once I corrected it everything went well. Jean-Pierre Rosen wrote: > Andrew a =E9crit : > > Hello, > > > > I am trying to do seperate compilation with a protected object. > > > > I have something similar to the following: > > > > =3D=3D=3D file tasks.ads =3D=3D=3D > > package Tasks is > > > > protected type Boob is > > . . . > > end Boob; > > end Tasks; > > > > =3D=3D=3D file tasks.adb =3D=3D=3D > > package body Tasks is > > > > protected body Boob is seperate; > > end Tasks; > > > > I am using Gnat3.15p on FreeBSD Unix. > > I get similar compilation messages to the below: > > tasks.adb:<#>:<#>: all components must be declared in spec > > ... > > > A wild guess, since you didn't show the body: > Didn't you declare components in the body? i.e. > > protected body Boob is > X : integer; -- Not allowed > .... > end Boob; > > Remember that a protected object is actually more like a record than a > package; it has no variables, only components (like record components), > and they are not allowed in the body. > > Presumably, this has nothing to do with separate compilation... > > -- > --------------------------------------------------------- > J-P. Rosen (rosen@adalog.fr) > Visit Adalog's web site at http://www.adalog.fr