How to use a function without their sources

nazriel spam at dzfl.pl
Fri Jan 18 10:23:55 PST 2013


On Friday, 18 January 2013 at 18:18:07 UTC, Andrej Mitrovic wrote:
> On 1/18/13, nazriel <spam at dzfl.pl> wrote:
>> extern(C) void _D3lib3fooFZv();
>>
>> void main() {
>> 	_D3lib3fooFZv();
>> }
>
> That's a *terrible* idea, you are calling a D function using 
> the C
> convention, you're going to have all sorts of problems. 
> extern(D) is
> not just used for mangling, it's also used for designating how
> parameters are passed to and results are returned from a 
> function (via
> stack/registers). E.g.:
>

Oh really?
Thanks, I didn't know.


More information about the Digitalmars-d-learn mailing list