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

Sven Barth pascaldragon at googlemail.com
Mon Oct 10 17:40:11 CEST 2011


Am 10.10.2011 16:59, schrieb Michael Lutz:
> Unfortunately, the second one is the interesting one as not using units is
> no option. Is this is a genuine bug or is a symbol containing a '?' not
> supported in units by design?
[skip]
> $ cat testunit.pas
> unit TestUnit;
>
> interface
>
> procedure Dummy;
>
> implementation
>
> procedure Dummy; external 'who_cares' name '?Dummy';
>
> end.

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.

Regards,
Sven



More information about the fpc-pascal mailing list