From: Simon Wright <simon@pushface.org>
Subject: Re: Elaboration circularity with generics
Date: Sat, 14 Jan 2012 22:46:31 +0000
Date: 2012-01-14T22:46:31+00:00 [thread overview]
Message-ID: <m2sjjhq4vs.fsf@pushface.org> (raw)
In-Reply-To: c660cabc-0745-4cd5-a5c9-610767835a50@g27g2000yqa.googlegroups.com
AdaMagica <christ-usch.grein@t-online.de> writes:
> A unit can only be instantiated if it is fully elaborated.
> I guess GNAT chose the elaboration order P'Spec, P.Q'Spec, P'Body
> (crash since P.Q'body is not elaborated).
> This dependence is not present for nongeneric units.
>
> Perhaps addition of pragma Elaborate_Body to P.Q helps.
with P.Q;
pragma Elaborate (P.Q); <<<<<<< does the trick for me
package body P is
I have to say that elaboration problems are often mindboggling (the best
I remember was when GNAT 3.09 reported an elaboration cycle of 157 where
there were only 156 units in the program).
next prev parent reply other threads:[~2012-01-14 22:46 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-01-14 15:09 Elaboration circularity with generics Maciej Sobczak
2012-01-14 16:13 ` Martin Dowie
2012-01-14 16:17 ` AdaMagica
2012-01-14 22:46 ` Simon Wright [this message]
2012-01-15 16:55 ` AdaMagica
2012-01-16 15:09 ` Simon Wright
2012-01-16 17:15 ` AdaMagica
2012-01-14 16:26 ` AdaMagica
2012-01-14 22:01 ` Georg Bauhaus
2012-01-15 17:15 ` Maciej Sobczak
2012-01-15 17:43 ` AdaMagica
2012-01-16 17:02 ` Adam Beneschan
2012-01-16 14:34 ` Robert A Duff
2012-01-16 21:29 ` Maciej Sobczak
2012-01-16 21:52 ` Adam Beneschan
2012-01-16 22:25 ` Robert A Duff
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox