From: Brian Rogoff <bpr@shell5.ba.best.com>
Subject: Re: Design Question: How Best To Structure Cross-Referencing Types In Ada 95
Date: 1999/01/21
Date: 1999-01-21T00:00:00+00:00 [thread overview]
Message-ID: <Pine.BSF.4.05.9901211753580.14680-100000@shell5.ba.best.com> (raw)
In-Reply-To: 787fku$k4m$1@nnrp1.dejanews.com
On Thu, 21 Jan 1999 dewar@gnat.com wrote:
> In article aeg@hiwaay.net, glover@thaad.tecmasters.com wrote:
> >
> > ... Ada withing problem description snipped ...
> > Is there a neat Ada95 way of getting around this
> > cross-referencing problem?
>
> This is an old and well discussed problem. Often you can
> introduce a third package with the types alone to at least
> factor this out, but the fundamental circularity problem
> remains and there is no solution in pure Ada 95.
>
> For JGNAT, the version of GNAT that generates code for the
> JVM, we have found it important to deal with this problem
> for the purpose of translating existing Java specs. We have
> therefore implemented an extension, based on Tucker's "with
> type" suggestion the last time around this was discussed,
> and this extension will be available (controlled by a
> switch of course) in version 3.12 of GNAT.
Is your extension going to use the same syntax as Tucker's proposal?
Matthew Heaney raised the objection that the syntax was a bit ugly, since
"with type" : "use type" is not the same relationship as "with" : "use"
(am I paraphrasing your objection correctly Matthew?) and so a better
syntax should be designed. I kind of agree, but I think the problem is
more with "use type", which I don't like.
Maybe next we'll see the signature extension from GNU-C++ on GNAT so that
we can write Java interface style code directly ;-).
> There are not many places where one can justify out and out
> extensions of the language (and indeed I suppose one could
> do this with a pragma, but it seems silly). This however,
> seems an exception, where an extension is really needed.
I thought ACT had a pragma for this; I recall reading about it from
ACT-Europe.
-- Brian
next prev parent reply other threads:[~1999-01-21 0:00 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
1999-01-20 0:00 Design Question: How Best To Structure Cross-Referencing Types In Ada 95 Anthony E. Glover
1999-01-21 0:00 ` dewar
1999-01-21 0:00 ` Brian Rogoff [this message]
1999-01-26 0:00 ` Dale Stanbrough
1999-01-21 0:00 ` dennison
1999-01-21 0:00 ` Matthew Heaney
1999-01-30 0:00 ` Nick Roberts
1999-01-31 0:00 ` Matthew Heaney
1999-01-22 0:00 ` Steve Whalen
1999-01-22 0:00 ` dennison
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox