- set_exception_handler: documentation ( source)
- restore_exception_handler: documentation ( source)
<?php
/**
* @link https://bugs.php.net/bug.php?id=62452
*/
set_exception_handler($handler = function($exception) {
restore_exception_handler(); // boom
echo "Exception handled, move along.\n";
});
throw new Exception; // fatal error: cannot destroy active lambda