From: "Dmitry A. Kazakov" <mailbox@dmitry-kazakov.de>
Subject: Re: discriminants, what are they?
Date: Mon, 18 Dec 2006 11:23:50 +0100
Date: 2006-12-18T11:23:47+01:00 [thread overview]
Message-ID: <aa0svfsddwez.8bzbv0bpcovf.dlg@40tude.net> (raw)
In-Reply-To: wccy7p69h60.fsf@shell01.TheWorld.com
On Sun, 17 Dec 2006 19:33:27 -0500, Robert A Duff wrote:
> "markww" <markww@gmail.com> writes:
>
>> Can explain what an Ada discriminant is? I found this definition but
>
> It's a parameter that can be passed to a type when making an object of
> the type, sort of like a parameter passed to a procedure when making a
> call to that procedure. It can be used inside the type to determine which
> variant you want, or the bounds of an array, or to pass further along to
> another discriminant of a component type, or in an expression that
> initializes a component.
>
> Another view: it's a constant component. Once you give a discriminant
> of a particular object a value, that value cannot change.
and with a subtype declaration some of the discriminants can be fixed to
distinct values, e.g. to produce "specializations."
--
Regards,
Dmitry A. Kazakov
http://www.dmitry-kazakov.de
next prev parent reply other threads:[~2006-12-18 10:23 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-12-17 23:57 discriminants, what are they? markww
2006-12-18 0:33 ` Robert A Duff
2006-12-18 0:43 ` markww
2006-12-18 10:23 ` Dmitry A. Kazakov [this message]
2006-12-18 9:35 ` gautier_niouzes
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox