[fpc-pascal] Linking to C++ DLL compiled with MSVC

2011-10-10 Thread Michael Lutz
I've been trying to link to an external DLL which is unfortunately compiled using MSVC in C++ mode. The functions itself do not use any C++ features, they are just not declared as extern "C" and thus use name mangling. With MSVC name mangling, each symbol starts with a '?' character, which seems t

[fpc-pascal] Re: Linking to C++ DLL compiled with MSVC

2011-10-10 Thread Michael Lutz
Am 10.10.2011 17:41 schrieb Sven Barth: > Move the "external ..." part to the interface and remove the one in the > implementation section. This works at least for me and is the usual way > of importing functions in their own unit. Thanks, that works. Summary of some more tests: - 'external ...'

[fpc-pascal] Re: Linking to C++ DLL compiled with MSVC

2011-10-10 Thread Michael Lutz
Am 10.10.2011 21:01 schrieb Sven Barth: > So could you report one, so it's not forgotten? Done: http://bugs.freepascal.org/view.php?id=20456 Michael ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listin