From: Stephen Leake <stephen.a.leake.1@gsfc.nasa.gov>
Subject: Re: Convert Integer_Address and Address?
Date: 01 Oct 2001 17:49:21 -0400
Date: 2001-10-01T21:50:58+00:00 [thread overview]
Message-ID: <u7kufyqse.fsf@gsfc.nasa.gov> (raw)
In-Reply-To: 9p9l2n$s5c$1@newstoo.ericsson.se
"Sebastian" <sebastian.madunic@esavionics.se> writes:
> Hi,
>
> �
>
> If you have a constant like this:
>
> �
>
> register_Address : constant 16#FE10_2000#;
>
> �
>
> and you use the function To_Address in System.Storage_Elements package, What
> will be the actual result?
You can think of System.Storage_Elements.To_Address as a simple type
conversion. That is, on a system with 32 bit addresses, To_Address
(register_Address) will return a value of type Address with the value
16#FE10_2000#.
On another system that has only 16 bit addresses, you might get
Constraint_Error or something.
> Will this mean that the variable register_Address� will get the
> adress 16#FE10_2000#?
'register_Address' is _not_ a variable; it does not occupy space in
RAM. In Ada terminology, it is a "named number"; in plain English,
it's a "constant".
I'm not sure what you are asking.
What are you doing with the result of the To_Address call? Show the
rest of the code!
--
-- Stephe
parent reply other threads:[~2001-10-01 21:49 UTC|newest]
Thread overview: expand[flat|nested] mbox.gz Atom feed
[parent not found: <9p9l2n$s5c$1@newstoo.ericsson.se>]
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox