A question about the GC

Jarrett Billingsley kb3ctd2 at yahoo.com
Sun Dec 23 20:40:50 PST 2007


"Jarrod" <qwerty at ytre.wq> wrote in message 
news:fkn8sd$sl0$1 at digitalmars.com...

> This is all well and good, but my concern is that the garbage collector
> may reallocate my class if it is a 'copying' gc (I'm not really sure what
> it really is, I can't see it mentioned anywhere). If my class is moved,
> what happens to the pointers in my C code? Will they be updated too? I
> doubt it.

As Kirk pointed out, D's current collector is a non-moving collector, but in 
the event that a moving collector is implemented, most moving collectors 
provide a method to "pin" a piece of memory to disallow it from being moved. 




More information about the Digitalmars-d-learn mailing list