On Wed, Jan 25, 2006 at 05:15:26PM +0100, demerphq wrote:
> On 1/25/06, Randy W. Sims <[EMAIL PROTECTED]> wrote:
> > Too tired to think properly, but...
> >
> > demerphq wrote:
> > > Also, something that would be really useful would be a way to force
> > > perl to close all files. Ie, to unload all dll's, close any intenral
> > > filehandles kept open for __DATA__ and __END__ etc. Then this batch
> > > file malarky would be totally unnecessary.

> IMO almost as important is the ability to force all the DATA handles
> closed. But the ability to unload DLL's is a big step forward.

I think that you can brute force that by walking the entire symbol table,
taking all the typeglobs named "DATA" and close()ing them.

If you want to be really really horrible and close all file handles (or a
subset such all handles that don't turn out to a tty), even those that are no
longer referenced via symbol tables, you can probably do this with XS by
walking the SV arenas.

Nicholas Clark

Reply via email to