[Pharo-project] Another finalization concern: error handling

Igor Stasenko siguctua at gmail.com
Mon Oct 11 12:14:11 EDT 2010


Meanwhile, i'll try to implement two test cases for WeakRegistryTest.

One, should cover following:

coll := OrderedCollection new.
obj := Object new.
wrapper := WeakArray with: obj.
coll add: wrapper.

obj toFinalizeSend: #remove: to: coll with: wrapper.
obj toFinalizeSend: #remove: to: coll with: wrapper.
obj toFinalizeSend: #remove: to: coll with: wrapper.
obj toFinalizeSend: #remove: to: coll with: wrapper.

obj := nil.
Smalltalk garbageCollect.

i.e somehow, user should be notified that there is an error during finalization.

And second test case is to make sure that if one finalizer unable to
complete due to error,
the other ones (and finalization process itself) should continue
running, skipping over errorneous finalizer.

-- 
Best regards,
Igor Stasenko AKA sig.




More information about the Pharo-dev mailing list