On 03/22/2010 08:32 PM, Robert Jacques wrote:
On Mon, 22 Mar 2010 19:00:57 -0300, Andrei Alexandrescu
<seewebsiteforem...@erdani.org> wrote:
[snip]
And the last idea before I forget (just talked to Walter about it) is
that the GC could and should offer functions:

GC.preCollect(void delegate());
GC.postCollect(void delegate());

That way we can effectively implement weak pointers.

Pre and post collect should be an array of delegates. Otherwise only one
person's weak pointer library would work.

Those are functions that you can call several times. The gc will keep indeed a container of delegates.

Andrei

Reply via email to