> > I was thinking about adding a `next' member to CObject, to build a > > singly-linked list of finalized objects without allocating memory. > > Unfortunately it would still probably require synchronization. > > With careful programming, synchronization should not be a problem. Though I > don't like the sound of delaying the finalization of the object. That may > just be as bad as allocating new objects during finalization. I think the point was to finalize the Java object and just mark the C object a "ready to be finalized" (mark could mean put it in a queue). That way the Tcl side can come along later a notice (in the Tcl interp thread) that there is a list of Tcl C objects that need to be freed up. Mo DeJong Red Hat Inc ---------------------------------------------------------------- The TclJava mailing list is sponsored by Scriptics Corporation. To subscribe: send mail to [EMAIL PROTECTED] with the word SUBSCRIBE as the subject. To unsubscribe: send mail to [EMAIL PROTECTED] with the word UNSUBSCRIBE as the subject. To send to the list, send email to '[EMAIL PROTECTED]'. An archive is available at http://www.mail-archive.com/tcljava@scriptics.com