From: "Robert I. Eachus" <rieachus@comcast.net>
Subject: Re: Problem with protected type
Date: Wed, 26 Nov 2003 10:43:32 -0500
Date: 2003-11-26T10:43:32-05:00 [thread overview]
Message-ID: <GdCdnQ8RKp61V1miRVn-sw@comcast.com> (raw)
In-Reply-To: <bq07lh$4oh$1@online.de>
Ekkehard Morgenstern wrote:
>>Replacing EventObject by a pointer to CoreEvent eliminates the need for
>>"knowing" the size of CoreEvent. Other fixes would be to complete the
>>declaration of CoreEvent before the declaration of BaseEvent,
>
> How could I declare the CoreEvent record layout as private without putting
> the declaration in the private section?
Hmmm. Let me change your question to, "...without putting the
declaration in SOME private part?"
The answer is you can't. But the private part which contains the
completion of CoreEvent need not be the one for the package that
declares BaseEvent. The best solution for this problem, when it occurs,
is to declare BaseEvent in a child package. I think we agreed though
that the right solution in this case is to make BaseEvent a protected
type, and create any objects of the type in the package private part, in
the package body, or elsewhere.
--
Robert I. Eachus
100% Ada, no bugs--the only way to create software.
next prev parent reply other threads:[~2003-11-26 15:43 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-11-25 15:15 Problem with protected type Ekkehard Morgenstern
2003-11-25 15:43 ` Ekkehard Morgenstern
2003-11-25 16:06 ` Robert I. Eachus
2003-11-25 18:39 ` Ekkehard Morgenstern
2003-11-26 15:43 ` Robert I. Eachus [this message]
2003-11-25 16:45 ` Ludovic Brenta
2003-11-25 18:45 ` Ekkehard Morgenstern
2003-11-25 20:09 ` Randy Brukardt
2003-11-25 18:03 ` Jeffrey Carter
2003-11-25 18:31 ` Ekkehard Morgenstern
2003-11-26 0:42 ` Jeffrey Carter
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox