[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Weak Arrays



On Oct 15, Ole Agesen replied to James Noble about using cannonical mirrors
that constructing a mirror table in Self would make un-collectable objects
in the table. (I'm using a primitive mailer, right now, so pardon the 
mistakes, please)  In ParcPlace's Smalltalk 4.0, they started using a gener-
ational garbage collector (like Self does) and they included a new type of
collection called a 'WeakArray,' which they use to solve exactly this type
of problem.  A weak array can have objects it references garbage collected
right out from under it.  Weak arrays are also periodically 'informed' when
their elements die, so that you can do some cleaning up if you want.

I'm sure this kind of thing isn't all that hard to implement (for all I know,
Self may already have something like this).  This would be a usefull addition
to the wish-list, if it isn't there, though..

		-- Bill