Allocating memory in D shared library when accessed from C++
Trass3r
un at known.com
Mon Dec 19 15:02:59 PST 2011
Am 19.12.2011, 23:13 Uhr, schrieb Martin Drašar <drasar at ics.muni.cz>:
> Dne 19.12.2011 23:09, Trass3r napsal(a):
>>> It actualy returns a procedure address and the procedure is called. It
>>> lands inside export extern (C) int magicNumber() and crashes when
>>> attempting to allocate memory for Something.
>>
>> Did you properly initialize druntime?
>
> As I am just starting with D, the most precise answer I can give you is:
> I don't know... how do I tell? Or in another way - the code for D
> library is almost complete except for imports. The rest was done for me
> by Visual D.
It's explained there: http://www.dlang.org/dll.html
More information about the Digitalmars-d-learn
mailing list