From: okellogg@freenet.de (Oliver Kellogg)
Subject: Actual subprogram and generic instantiation in same unit
Date: 27 Oct 2003 04:33:25 -0800
Date: 2003-10-27T04:33:25-08:00 [thread overview]
Message-ID: <6a6390b8.0310270433.6b916549@posting.google.com> (raw)
To my amazement the following compiles:
-- file: inst.ads
with Generic_Package; -- takes a parameterless generic formal procedure P
package Lump is
procedure Manipulate;
package Instantiation is new Generic_Package (P => Manipulate);
end Lump;
Poor compiler has to instantiate a package using a procedure
whose body it has not yet seen...
Is that considered good Ada style?
Are there cases where this lumping together could cause problems?
Thanks,
Oliver M. Kellogg
next reply other threads:[~2003-10-27 12:33 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-10-27 12:33 Oliver Kellogg [this message]
2003-10-27 13:20 ` Actual subprogram and generic instantiation in same unit Duncan Sands
2003-10-30 13:35 ` Oliver Kellogg
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox