in reply to How do I make the garbage collector throw an exception when it fails to auto-close a filehandle?
Untested idea:
- Create a subclass of IO::Handle or IO::File with a custom DESTROY subroutine that closes (if open) with error handling.
- Use the subclass instead of basic filehandles.
In Section
Seekers of Perl Wisdom