comp.lang.ada
 help / color / mirror / Atom feed
* Passing indefinite types
@ 2013-02-02 21:07 sbelmont700
  2013-02-02 21:31 ` Jeffrey Carter
                   ` (3 more replies)
  0 siblings, 4 replies; 12+ messages in thread
From: sbelmont700 @ 2013-02-02 21:07 UTC (permalink / raw)


Hi,

Does anyone know of a slick way to pass several locally declared, indefinite types to a subprogram without resorting to the heap or Unchecked_Access?  An array of indefinite types is obviously not possible, an array of named access types is subject to accessibility problems, and wrapping the object in an 'accessor' (i.e. a null record with an access discriminant) turns right back into a problem of an array of indefinite types.  I can always declare a procedure that takes a bunch of individual parameters, but this seems like a kludge, and doesn't solve the problem if the number of items might vary.  It would be nice if there was some way to establish that a discriminated record is in fact a fixed size, or perhaps if an array of anonymous access types had the same accessibility as access discriminants.  But if anyone knows of a workaround, I would be interested in how it was done.

Thank you.

-sb




^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2013-02-05 21:16 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-02-02 21:07 Passing indefinite types sbelmont700
2013-02-02 21:31 ` Jeffrey Carter
2013-02-03  0:27   ` sbelmont700
2013-02-03  8:07     ` Dmitry A. Kazakov
2013-02-03 10:22 ` gautier_niouzes
2013-02-03 22:26 ` Stephen Leake
2013-02-04  1:25   ` sbelmont700
2013-02-04  3:46     ` Shark8
2013-02-05  2:40     ` Randy Brukardt
2013-02-05 13:01     ` Stephen Leake
2013-02-05 20:56       ` Randy Brukardt
2013-02-05 21:16 ` sbelmont700

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