summaryrefslogtreecommitdiff
path: root/Zend/tests/try_finally_008.phpt
diff options
context:
space:
mode:
Diffstat (limited to 'Zend/tests/try_finally_008.phpt')
-rw-r--r--Zend/tests/try_finally_008.phpt21
1 files changed, 21 insertions, 0 deletions
diff --git a/Zend/tests/try_finally_008.phpt b/Zend/tests/try_finally_008.phpt
new file mode 100644
index 0000000000..cee37aedab
--- /dev/null
+++ b/Zend/tests/try_finally_008.phpt
@@ -0,0 +1,21 @@
+--TEST--
+Try finally (with break in do...while)
+--FILE--
+<?php
+function foo () {
+ do {
+ try {
+ try {
+ } finally {
+ break;
+ }
+ } catch (Exception $e) {
+ } finally {
+ }
+ } while (0);
+}
+
+foo();
+?>
+--EXPECTF--
+Fatal error: jump out of a finally block is disallowed in %stry_finally_008.php on line %d