tokuhirom's Blog

$? in END/destructor

END routines and destructors can change the exit status by modifying $? .
http://perldoc.perl.org/functions/exit.html

Heh. It causes a issue on Proc::Guard + prove. prove watches exit status of test script.

You can see the changes from here:
https://metacpan.org/diff/release/TOKUHIROM/Proc-Guard-0.05/TOKUHIROM/Proc-Guard-0.06#lib/Proc/Guard.pm