Re: Calling conventions <mainly windows>

Alexander Olk <[email protected]>
Newsgroups gmane.comp.lib.wxwindows.wxnet
Message-ID <1088516200.6106.22.camel@Dellkiste>
Am Di, den 29.06.2004 schrieb William um 8:46:
> I did a little digging and found that WXEXPORT is
> defined as __declspec(dllexport) and nothing else.

Correct...

> What's my point?, well as far as I understand (and I
> could be wrong) if you don't include the __stdcall
> directive in an exported method then that method will
> be exported under the cdecl calling convention.  I
> mention this since all the DLLImport directive in your
> C# classes seem to not be specifying that the methods
> are in fact cdecl methods.

DllImport does the work for us. There is no need for __stdcall
or __cdecl (except callback functions...).
Take a look at:
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/csref/html/vclrfExternPG.asp

> Once I changed all my imports to cdecl in my Delphi
> program things started to work fine.

Well, Delphi :)))

Alexander Olk




-------------------------------------------------------
This SF.Net email sponsored by Black Hat Briefings & Training.
Attend Black Hat Briefings & Training, Las Vegas July 24-29 - 
digital self defense, top technical experts, no vendor pitches, 
unmatched networking opportunities. Visit www.blackhat.com
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.