comp.lang.ada
 help / color / mirror / Atom feed
From: "Randy Brukardt" <randy@rrsoftware.com>
Subject: Re: Choice of variant record discriminant (design question)
Date: Wed, 26 Oct 2005 14:52:23 -0500
Date: 2005-10-26T14:52:23-05:00	[thread overview]
Message-ID: <fP2dnZ4nFtAFQMLenZ2dnUVZ_smdnZ2d@megapath.net> (raw)
In-Reply-To: m2acgwmpsu.fsf@hugin.crs4.it

"Jacob Sparre Andersen" <sparre@nbi.dk> wrote in message
news:m2acgwmpsu.fsf@hugin.crs4.it...
...
> but I have a feeling there ought to be a more elegant solution.  Does
> somebody have a suggestion or two?

I have to wonder if the variant is worth it. There is not going to be any
space savings, and in typical use, there isn't going to be much increase in
safety, either. So I'd probably give up on the variant in this case, because
I'd rather keep the aggregates (they are big help when a component needs to
be added). But only you can weight that trade-off, because the relative
value of the two options is something that depends on the components and the
intended uses. (If the "empty" variant wasn't going to be empty in future
version, for instance, the variant would make more sense.)

                        Randy.







  parent reply	other threads:[~2005-10-26 19:52 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-10-26 12:21 Choice of variant record discriminant (design question) Jacob Sparre Andersen
2005-10-26 13:14 ` christoph.grein
2005-10-26 13:26   ` Jacob Sparre Andersen
2005-10-26 17:52 ` Jeffrey R. Carter
2005-10-26 19:52 ` Randy Brukardt [this message]
2005-10-31 15:53   ` Jacob Sparre Andersen
replies disabled

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