[gclist] Near death notices.

Charles Fiterman cef@geodesic.com
Mon, 08 Oct 2001 10:00:18 -0500


I've changed my mind on the issue of finalizers a few times and really like
Nick Barne's messages which I call near death notices. They say the object
you wanted to know about is near death and here is the final thread holding
it to life. You may cut the thread or tie it elsewhere. You may also
request another near death notice.

I like the idea that a near death notice would hold a weak pointer to an
object before it was sent and a regular pointer after. Sending it should
mean taking it off one double linked list and putting it on another. The
near death notice would specify which list it needed to be put on.

This allows lists for various purposes and traversal of lists at program
shutdown.