From: dennison@telepath.com
Subject: Re: Can I have an array of variant records?
Date: 1999/04/22
Date: 1999-04-22T00:00:00+00:00 [thread overview]
Message-ID: <7fndrd$ijp$1@nnrp1.dejanews.com> (raw)
In-Reply-To: 87k8v5oazn.fsf@bglbv.my-dejanews.com
In article <87k8v5oazn.fsf@bglbv.my-dejanews.com>,
bglbv@my-dejanews.com wrote:
> Robert Dewar <robert_dewar@my-dejanews.com> writes:
>
> > Of course typical compilers will allocate the maximum space
> > for each element, so if this is not acceptable, you will
> > indeed need to use pointers.
>
> Aha. So it isn't enough _in practice_ to give the discriminant a
> default value: one also needs to pick its subtype carefully.
> How big is Positive'Last on a typical implementation, I wonder?
> (>= 32767, I know.) Still, this looks cleaner than my Bounded_String
> suggestion.
Very perceptive of you. Yes, I have seen people get STORAGE_ERROR at runtime
(in Ada 83) for that exact reason. Some compilers are even smart enough to
point this out to you.
--
T.E.D.
-----------== Posted via Deja News, The Discussion Network ==----------
http://www.dejanews.com/ Search, Read, Discuss, or Start Your Own
next prev parent reply other threads:[~1999-04-22 0:00 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
1999-04-20 0:00 Can I have an array of variant records? Josh Highley
1999-04-20 0:00 ` bglbv
1999-04-21 0:00 ` Robert Dewar
1999-04-21 0:00 ` Pawel Kobylarz
1999-04-21 0:00 ` David C. Hoos, Sr.
1999-04-21 0:00 ` Robert Dewar
1999-04-21 0:00 ` dennison
1999-04-21 0:00 ` Robert Dewar
1999-04-22 0:00 ` Josh Highley
1999-04-23 0:00 ` Pawel Kobylarz
1999-04-21 0:00 ` czgrr
1999-04-21 0:00 ` bglbv
1999-04-22 0:00 ` dennison [this message]
1999-04-21 0:00 ` Robert Dewar
1999-04-22 0:00 ` Maybe not exactly a variant record Josh Highley
1999-04-22 0:00 ` dennison
1999-04-23 0:00 ` Nick Roberts
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox