2008-07-13 21:37:27 +00:00
|
|
|
--TEST--
|
|
|
|
Setting previous exception
|
|
|
|
--FILE--
|
|
|
|
<?php
|
|
|
|
|
|
|
|
try {
|
2020-02-03 21:52:20 +00:00
|
|
|
try {
|
|
|
|
throw new Exception("First", 1, new Exception("Another", 0, NULL));
|
|
|
|
}
|
|
|
|
catch (Exception $e) {
|
|
|
|
throw new Exception("Second", 2, $e);
|
|
|
|
}
|
2008-07-13 21:37:27 +00:00
|
|
|
}
|
|
|
|
catch (Exception $e) {
|
2020-02-03 21:52:20 +00:00
|
|
|
throw new Exception("Third", 3, $e);
|
2008-07-13 21:37:27 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
?>
|
|
|
|
===DONE===
|
|
|
|
--EXPECTF--
|
2015-05-17 16:35:18 +00:00
|
|
|
Fatal error: Uncaught Exception: Another in %sexception_007.php:%d
|
2008-07-13 21:37:27 +00:00
|
|
|
Stack trace:
|
|
|
|
#0 {main}
|
|
|
|
|
2015-05-17 16:35:18 +00:00
|
|
|
Next Exception: First in %sexception_007.php:%d
|
2008-07-13 21:37:27 +00:00
|
|
|
Stack trace:
|
|
|
|
#0 {main}
|
|
|
|
|
2015-05-17 16:35:18 +00:00
|
|
|
Next Exception: Second in %sexception_007.php:%d
|
2008-07-13 21:37:27 +00:00
|
|
|
Stack trace:
|
|
|
|
#0 {main}
|
|
|
|
|
2015-05-17 16:35:18 +00:00
|
|
|
Next Exception: Third in %sexception_007.php:%d
|
2008-07-13 21:37:27 +00:00
|
|
|
Stack trace:
|
|
|
|
#0 {main}
|
|
|
|
thrown in %sexception_007.php on line %d
|