Hooking the GC?

%u wfunction at hotmail.com
Sun Jan 2 19:34:55 PST 2011


Hi,

Is there any way to add a hook to the garbage collector in D, so that I can be
immediately notified (for example) when an object is created?

(I'm aware that this could cause infinite recursion/deadlock if I try to
allocate memory, but that's all right, I'm fine with that.)

Thank you!


More information about the Digitalmars-d mailing list