%u <[email protected]> wrote:
Hi,Is there any way to add a hook to the garbage collector in D, so that I can beimmediately 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.)
You're gonna have to add such functionality to the GC by yourself, I'm afraid. Shouldn't be too hard though, depending on what sort of info you require from the hook. -- Simen
