Re: Calling C++ procedures from Ada - Linkage problem
- From: Vinzent 'Gadget' Hoefler <nntp-2005-05@xxxxxxxxxxxxxxxxxxx>
- Date: Tue, 24 May 2005 10:55:05 +0000
Ken Resander wrote:
[...]
> /*
> void calltosee ( )
> {
> // called this from a c++ program compiled and linked by
> // VC6. Used disassembler in debug window and
> // found that:
> int h ;
> char dst [ 100 ] ;
> openhandler_c ( &h) ; // this contains a _chkesp call
[...]
Well, it seems that VC++ is generating the stack checking stuff. A web
search seems to reveal that this is only when "VC generates debug
code" (whatever this means). ;) So I'd say, switch VC to "release code
generation" (whatever that might mean) or just declare an Ada routine
called chkesp with C interface (well, "pragma Inline" won't work then,
I suppose).
BTW, according to
<URI:http://www.winehq.com/hypermail/wine-patches/2003/03/att-0132/01-msvcrt_chesp.diff>
the routine is contained in the msvcrt dll.
Vinzent.
--
worst case: The wrong assumption there actually is one.
.
- Prev by Date: Re: SPARK and Interfaces.C
- Next by Date: Re: gnat: symbolic traceback on exceptions
- Previous by thread: Visit my web-page http://www.angelfire.com/un/00
- Next by thread: Implementing Ada.Asynchronous_Task_Control in GNAT
- Index(es):