What can you "new"

Sean Kelly sean at invisibleduck.org
Wed Mar 25 07:42:22 PDT 2009


Cristian Vlasceanu wrote:
>>> Do custom-allocated objects live on the GC-ed heap?
>> Not necessarily, e.g. you can malloc some memory and then create an object 
>> there.
>>
> 
> I was afraid that may be the case, and it is perhaps not a good idea.

I think this is unavoidable if D wants to be a "real" systems language, 
because shared memory use is pretty common in such apps.  D has this now 
with custom new/delete methods, but if these are eliminated then there 
would have to be some kind of substitute.  They certainly wouldn't be 
commonly used, but this has to at least be possible.



More information about the Digitalmars-d mailing list