comp.lang.ada
 help / color / mirror / Atom feed
From: Florian Weimer <fw@s.netic.de>
Subject: Re: Problem with instantiating generic procedure
Date: 1999/07/17
Date: 1999-07-17T19:07:50+00:00	[thread overview]
Message-ID: <m3u2r3p01l.fsf@deneb.cygnus.stuttgart.netsurf.de> (raw)
In-Reply-To: 7mqfcq$9og$1@pegasus.csx.cam.ac.uk

mgk25@cl.cam.ac.uk (Markus Kuhn) writes:

> Sorry, but after searching through the RM for almost an hour, I still
> haven't figured out what I do wrong here and how I should fix this.

ARM 6.1(20):

| A subprogram_declaration or a generic_subprogram_declaration requires
| a completion: a body, a renaming_declaration (see 8.5), or a pragma
| Import (see B.1). A completion is not allowed for an
| abstract_subprogram_declaration.

I guess this means that an instance of a generic subprogram isn't allowed
as a completion for a subprogram declaration.  The obvious workaround
is using a renaming declaration.  Of course, the GNAT error message
could be a bit more helpful.

BTW: I stumbled across this problem and the solution while a solving
the very first Ada exercise of my computer science course. ;)




  parent reply	other threads:[~1999-07-17  0:00 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1999-07-17  0:00 Problem with instantiating generic procedure Markus Kuhn
1999-07-17  0:00 ` Vladimir Olensky
1999-07-17  0:00 ` Florian Weimer [this message]
1999-07-18  0:00   ` Markus Kuhn
1999-07-18  0:00     ` Florian Weimer
1999-07-19  0:00       ` Robert Dewar
1999-07-19  0:00         ` Florian Weimer
1999-07-18  0:00     ` Chad R. Meiners
1999-07-18  0:00 ` David C. Hoos, Sr.
1999-07-19  0:00 ` Robert A Duff
1999-07-19  0:00 ` Tucker Taft
1999-07-19  0:00   ` Markus Kuhn
1999-07-23  0:00     ` Tucker Taft
replies disabled

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