Re: StdCall vs. CDecl
- From: "Bob Altman" <rda@xxxxxxxxxxxxx>
- Date: Fri, 11 Jul 2008 18:48:11 -0700
You may want to reread what I wrote. stdcall is the default, cdecl is the oddThat's why it's customary to use stdcall for exported DLL functions, just
like the Win32 API does across the board.
So, why is StdCall the default if it's usually incorrect? (I'm going to
guess that it's a COM thing.)
one out.
Oh!!! We have a bunch of DLLs that all use CDecl because that's the default
that Visual Studio gives us. We also have a bunch of Ada and FORTRAN code that
calls into those libraries, probably using StdCall semantics (none of our code
in either language uses any keywords to specify the calling convention, so I
would hope that they choose StdCall by default). We're probably leaking some
stack space with each call. I guess I need to go through all of our native
library projects and change them to use StdCall, and do the same with all of our
managed code (all of which, today, explicitly uses CDecl when calling into our
libraries).
.
- Follow-Ups:
- Re: StdCall vs. CDecl
- From: Jeroen Mostert
- Re: StdCall vs. CDecl
- References:
- StdCall vs. CDecl
- From: Bob Altman
- Re: StdCall vs. CDecl
- From: Jeroen Mostert
- Re: StdCall vs. CDecl
- From: Bob Altman
- Re: StdCall vs. CDecl
- From: Jeroen Mostert
- StdCall vs. CDecl
- Prev by Date: Re: StdCall vs. CDecl
- Next by Date: Re: StdCall vs. CDecl
- Previous by thread: Re: StdCall vs. CDecl
- Next by thread: Re: StdCall vs. CDecl
- Index(es):
Relevant Pages
|