in reply to Re^2: Trapping re 'debug'
in thread Trapping re 'debug'

The reason you only see the DESTROY in your class is because you closed STDERR, then tied it to your class, but in your class you do nothing with it. So then when re 'debug' attempts to print STDERR, perl find that the handle is closed and reopens it before it can output to it. This process of reopening destroys your handle. You get the DESTROY call.

Replies are listed 'Best First'.
Re^4: Trapping re 'debug'
by diotalevi (Canon) on Jan 27, 2003 at 17:38 UTC

    Fair enough. I removed the call to close STDERR, left the tie *STDERR, TrapRe line in and I still only get the 'DESTROY' note. So at that point I'm just tying the existing STDERR handle but the tied object methods aren't being triggered at all.


    Seeking Green geeks in Minnesota