summaryrefslogtreecommitdiff
path: root/ext/opcache/tests/ssa_bug_004.phpt
diff options
context:
space:
mode:
Diffstat (limited to 'ext/opcache/tests/ssa_bug_004.phpt')
-rw-r--r--ext/opcache/tests/ssa_bug_004.phpt19
1 files changed, 19 insertions, 0 deletions
diff --git a/ext/opcache/tests/ssa_bug_004.phpt b/ext/opcache/tests/ssa_bug_004.phpt
new file mode 100644
index 0000000000..20e313045a
--- /dev/null
+++ b/ext/opcache/tests/ssa_bug_004.phpt
@@ -0,0 +1,19 @@
+--TEST--
+Assign elision exception safety: ICALL
+--FILE--
+<?php
+
+set_error_handler(function() { throw new Exception; });
+
+function test() {
+ $x = str_replace(['foo'], [[]], ['foo']);
+}
+try {
+ test();
+} catch (Exception $e) {
+ echo "caught\n";
+}
+
+?>
+--EXPECT--
+caught