bug63206_2.phpt 464 B

1234567891011121314151617181920212223242526
  1. --TEST--
  2. Bug #63206 Fully support exception_handler stacking, even with null
  3. --FILE--
  4. <?php
  5. set_exception_handler(function() {
  6. echo 'First handler' . PHP_EOL;
  7. });
  8. set_exception_handler(function() {
  9. echo 'Second handler' . PHP_EOL;
  10. });
  11. set_exception_handler(null);
  12. set_exception_handler(function() {
  13. echo 'Fourth handler' . PHP_EOL;
  14. });
  15. restore_exception_handler();
  16. restore_exception_handler();
  17. throw new Exception();
  18. ?>
  19. --EXPECT--
  20. Second handler