Export GC memory manager to C???

Sean Kelly sean at invisibleduck.org
Thu Jul 28 17:08:07 PDT 2011


On Jul 28, 2011, at 3:31 AM, Robert Persson wrote:

> Would it be possible to export GC.malloc(...) as a C function in a DLL, to use as a garbage collected memory allocator for C ? Or does the garbage collector not scan outside the boundaries of the DLL?

It's already exported in that the GC calls are all extern (C).  You may have to call thread_attachThis() in the C thread so the GC will scan it though.


More information about the Digitalmars-d mailing list