Sometimes its *really* hard to kill some objects. It seems that inspecting a list of pointersTo creates additional hanging references. This was frustrating me just now, so I finally hacked a way forward. Sharing it in case its useful to others, and also I can find it again searching the list. This needs to run for each object.
Smalltalk garbageCollect. target := ClassOfObjectsThatMustDie allInstances first. SystemNavigation default allObjectsDo: [ :e | (e isKindOf: Association) ifTrue: [ e value = target ifTrue: [ e value: nil ] ]. (e isKindOf: Array) ifTrue: [ 1 to: e size do: [ :i | (e at: i) = target ifTrue: [ e at: i put: nil ] ] ] ]. target := nil. Smalltalk garbageCollect. cheers -ben
