* Do subtypes inherit the attributes of the base type?
@ 2001-08-28 20:52 Raymond Rawa
0 siblings, 0 replies; only message in thread
From: Raymond Rawa @ 2001-08-28 20:52 UTC (permalink / raw)
I'm migrating my code from VADS Ada83 to GHS Ada95 and I've got a type
that may be giving me trouble.
type Eng_Oil_Level_Calculation_Type is delta 1.0/2.0**10
range (System.Min_Int / 2) * 1.0/2.0**10 ..
(System.Max_Int / 2) * 1.0/2.0**10;
for Eng_Oil_Level_Calculation_Type'small use 1.0/2.0**10;
subtype Eng_Oil_Level_Type is Eng_Oil_Level_Calculation_Type
range -1.0..0.9990234375;
The legacy software is assuming that the subtype has the same 'small
value as the base type. Is this a safe assumption?
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2001-08-28 20:52 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-08-28 20:52 Do subtypes inherit the attributes of the base type? Raymond Rawa
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox