comp.lang.ada
 help / color / mirror / Atom feed
From: "Randy Brukardt" <randy@rrsoftware.com>
Subject: Re: Elaboration of nested generic package.
Date: Tue, 15 Jul 2003 12:19:12 -0500
Date: 2003-07-15T12:19:12-05:00	[thread overview]
Message-ID: <vh8dpifpmicl78@corp.supernews.com> (raw)
In-Reply-To: 1ec946d1.0307141035.3f1e4b80@posting.google.com

"Matthew Heaney" <mheaney@on2.com> wrote in message
news:1ec946d1.0307141035.3f1e4b80@posting.google.com...
> Is this normal behavior?  This is the reason I was asking whether the
> categorization pragmas do anything if they're declared in a generic
> package.
>
> Is it necessary to use a categorization pragma on library-level
> package instantiations?

GNAT is correct. The corrigendum says in 10.1.5(7.1/1):

A library unit pragma that applies to a generic unit does not apply to its
instances, unless a specific rule for the pragma specifies the contrary.

That means that a categorization pragma does not apply to instances of the
generic, only to the generic itself. (You need to be able to say that a
generic is Pure so it can be withed and instantiated in a Pure package; but
that doesn't necessaryly make it Pure - that depends on the formals).

The pragma on the instance is not "confirming"; it gives the categorization.

See AI-00041 for a full discussion.

                          Randy.






  reply	other threads:[~2003-07-15 17:19 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-07-02  4:13 Elaboration of nested generic package christoph.grein
2003-07-08  3:05 ` Don Westermeyer
2003-07-08 17:46   ` Matthew Heaney
2003-07-10  1:10     ` Don Westermeyer
2003-07-10  1:35       ` Robert I. Eachus
2003-07-10  4:51         ` Robert I. Eachus
2003-07-10  6:58           ` Jean-Pierre Rosen
2003-07-10 15:08             ` Robert I. Eachus
2003-07-11 21:26             ` Robert A Duff
2003-07-10 14:12         ` Matthew Heaney
2003-07-10 15:39           ` Robert I. Eachus
2003-07-11 21:41           ` Robert A Duff
2003-07-14 18:35             ` Matthew Heaney
2003-07-15 17:19               ` Randy Brukardt [this message]
2003-07-16 15:24                 ` Matthew Heaney
2003-07-17  2:08                   ` Randy Brukardt
2003-07-17 15:54                     ` Richard Riehle
2003-07-10 15:03         ` Don Westermeyer
2003-07-10 15:45       ` Matthew Heaney
  -- strict thread matches above, loose matches on Subject: below --
2003-07-09  5:21 christoph.grein
2003-07-01 20:14 Don Westermeyer
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox