From: Martin Krischik <krischik@users.sourceforge.net>
Subject: Re: Where are returned values stored? (follow up to yesterday's question)
Date: Thu, 27 May 2004 19:07:29 +0200
Date: 2004-05-27T19:07:29+02:00 [thread overview]
Message-ID: <3530449.K4d6KCzPc5@linux1.krischik.com> (raw)
In-Reply-To: 75s9b0pgo91ctvlm5op2rcql82t9ip4me2@4ax.com
James Alan Farrell wrote:
> Hello again,
> This is a followup to the question I asked yesterday. Below is a bit
> of code from GNAT's ASIS library. (I imagine this was written by
> people with a lot more expertise in Ada than I have, and that this
> code is okay.)
>
> It has a declarative part in the middle of the code, in which a
> variable (Result) is declared. The stuff in that variable is
> returned.
>
> Now its my understanding that when variables are declared like this,
> they are added onto the stack, then when the function returns, they
> are popped off again, along with the regular stack frame. So the
> stuff returned goes away.
In addition to the other explanation you should be aware the the way this is
done depends if convention C, Ada or DLL is used.
I have made good experience with passing from Ada to C using convention DLL.
Convention C has not worked with all C compilers on Windows.
With Regards
Martin
--
mailto://krischik@users.sourceforge.net
http://www.ada.krischik.com
prev parent reply other threads:[~2004-05-27 17:07 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-05-26 19:46 Where are returned values stored? (follow up to yesterday's question) James Alan Farrell
2004-05-26 20:44 ` Simon Wright
2004-05-27 7:51 ` Dmitry A. Kazakov
2004-05-27 9:39 ` Where are returned values stored? Marius Amado Alves
2004-05-27 17:05 ` Warren W. Gay VE3WWG
2004-05-27 20:24 ` James Alan Farrell
2004-05-28 20:33 ` Warren W. Gay VE3WWG
2004-05-29 7:03 ` Martin Krischik
2004-05-29 13:19 ` Larry Kilgallen
2004-05-30 7:10 ` Martin Krischik
2004-06-02 3:14 ` Robert I. Eachus
2004-05-30 21:17 ` Nick Roberts
2004-05-31 12:58 ` Warren W. Gay VE3WWG
2004-06-02 4:07 ` Robert I. Eachus
2004-06-02 12:42 ` Warren W. Gay VE3WWG
2004-06-03 2:00 ` Nick Roberts
2004-06-03 4:34 ` Robert I. Eachus
2004-06-03 16:06 ` Warren W. Gay VE3WWG
2004-06-03 16:13 ` Nick Roberts
2004-06-07 1:53 ` Robert I. Eachus
2004-06-07 13:09 ` Larry Kilgallen
2004-06-09 7:03 ` Robert I. Eachus
2004-06-05 17:13 ` Simon Wright
2004-05-27 17:11 ` Martin Krischik
2004-05-27 17:07 ` Martin Krischik [this message]
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox