emplacing extern(C++) class
drug via Digitalmars-d-learn
digitalmars-d-learn at puremagic.com
Mon Jan 16 02:45:24 PST 2017
I'm interfacing to C++ I using emplacing extern(C++) to malloc'ed memory
like http://wiki.dlang.org/Memory_Management (see Explicit Class
Instance Allocation)
This code segfaulted with extern(C++) TestClass.
I guess it's because extern(C++) class aren't rooted from Object so
instead of destroy(obj) (in heapDeallocation) I should use obj.__dtor()?
It works, but I'm not expert and so not sure.
Could someone confirm or no my thoughts?
Thank in advance
More information about the Digitalmars-d-learn
mailing list