comp.lang.ada
 help / color / mirror / Atom feed
From: smize@news.imagin.net (Samuel Mize)
Subject: Re: Address to function pointer conversion
Date: 1997/06/13
Date: 1997-06-13T00:00:00+00:00	[thread overview]
Message-ID: <5nrv4p$340m$1@prime.imagin.net> (raw)
In-Reply-To: 5nrq5h$13cm@info4.rus.uni-stuttgart.de


In article <5nrq5h$13cm@info4.rus.uni-stuttgart.de>,
Michael Paus <michael@ifr16.luftfahrt.uni-stuttgart.de> wrote:
[reformatted for length]
> I just stumbled over a little problem. I have a system address and I
> would like to convert it to an access to function type. How can this
> be done correctly?

Depends on how you define "correctly."

There is no such conversion defined within the language, because the
language would need some way to verify that this address is the
correct place to enter a routine with the given profile.

>PS: I currently just use an unchecked conversion which just works fine,

That's the only way I can imagine.  It is NOT "incorrect", but it IS
extremely compiler-dependent.  If you port to a different platform,
compiler brand, or compiler VERSION, you'll need to re-verify that this
works right.

Sam Mize

-- 
Samuel Mize -- smize@imagin.net -- Team Ada
(personal net account)




  reply	other threads:[~1997-06-13  0:00 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1997-06-13  0:00 Address to function pointer conversion Michael Paus
1997-06-13  0:00 ` Samuel Mize [this message]
1997-06-14  0:00   ` Robert Dewar
1997-06-13  0:00 ` John G. Volan
1997-06-14  0:00   ` Robert Dewar
1997-06-17  0:00     ` John G. Volan
1997-06-20  0:00       ` Robert Dewar
1997-06-24  0:00         ` Matthew Heaney
1997-06-24  0:00           ` Robert Dewar
1997-06-25  0:00             ` Michael Paus
1997-06-14  0:00 ` Robert Dewar
1997-06-16  0:00   ` Michael Paus
1997-06-16  0:00     ` Robert A Duff
1997-06-16  0:00     ` Robert Dewar
1997-06-16  0:00       ` Samuel Mize
1997-06-16  0:00         ` Robert A Duff
1997-06-17  0:00         ` Robert Dewar
1997-06-17  0:00           ` Samuel Mize
1997-06-20  0:00             ` Robert Dewar
1997-06-20  0:00             ` Robert Dewar
1997-06-14  0:00 ` Robert A Duff
replies disabled

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