Leopold Toetsch <[EMAIL PROTECTED]> writes: > Dan Sugalski <[EMAIL PROTECTED]> wrote: > > > No. If any object has a destructor it should be called as the last > > interpreter is shut down. We're not guaranteeing dead-on immediate > > destruction, or if the timely flag isn't set timely destruction, but we > > *are* guaranteeing eventual destruction. > > Oha. That explains the reasoning. That adds a third category to > "destruction" IMHO: > > 1) timely destruction on scope exits > 2) eventual destruction on exit of interpreters or any time between the death of the object and the and of universe^H^H^Hinterpreter. But no guarantee when.
> 3) memory destruction for leak tests and such or for intermediate > interpreters. > > For 1) we have opcode support C<needs_destroy>. 2) seems to be the case > where IO objects jump in - and HLL destructors. > > > We don't need to free memory, but we do need to call destructors. > > So we'd better separate 2) and 3) This would simplify destruction > ordering and speedup interpreter shutdown. The code is already there. The final sweep runs the destructors. The problem was that 1) and 2) were to strongly coupled. All destructors were only run if one object exists which needed timely destruction. Maybe we should generate another PMC which uses destruction functions, just for testing these things. bye boe -- Juergen Boemmels [EMAIL PROTECTED] Fachbereich Physik Tel: ++49-(0)631-205-2817 Universitaet Kaiserslautern Fax: ++49-(0)631-205-3906 PGP Key fingerprint = 9F 56 54 3D 45 C1 32 6F 23 F6 C7 2F 85 93 DD 47