bug72057.phpt 464 B

12345678910111213141516171819
  1. --TEST--
  2. Bug #72057 (PHP hangs when user error handler throws exception after Notice from type coercion)
  3. --FILE--
  4. <?php
  5. set_error_handler(
  6. function() {
  7. throw new Exception("My custom error");
  8. }
  9. );
  10. (function (int $i) { bar(); })("7as");
  11. --EXPECTF--
  12. Fatal error: Uncaught Exception: My custom error in %s:%d
  13. Stack trace:
  14. #0 %s(%d): {closure}(8, 'A non well form...', '%s', %d, Array)
  15. #1 %s(%d): {closure}('7as')
  16. #2 {main}
  17. thrown in %s on line %d