Hi, thats what local does for globals :) it saves the value until the end of the scope/block
{ local $SIG{__DIE__} = ...; } ## no sig handler here doEval(); sub doEval { local $SIG{__DIE__} = ...; ... } ## the end
In reply to Re^2: Custom SIG DIE handler that isn't executed in evals
by Anonymous Monk
in thread Custom SIG DIE handler that isn't executed in evals
by tunafish
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |