|
From: Samuele P. <ped...@bl...> - 2001-11-01 14:59:00
|
[Finn] > [Samuele] > > >Make sense, but I would not consider that a reverse of initialize > >but an helper for calling sys.exitfunc when deemed necessary > >(e.g. in presence of a SystemExit exception). > > It may eventually do other stuff (such as close open files) so I will > prefer a generic name. Something like "finalize". My point is that initialize must be called only once. For exitfunc we should either choose to make it static or an instance field of PySystemState, so it would there could be multiple versions of it. In particular I can imagine (rare) situations where you possibly have multiple interpreters and you would call finalize more than once. So I don't see it as the symmetric of initialize. I should admit I have checked CPython wrt these aspects. Samuele. |