xref: /PHP-8.4/ext/opcache/tests/jit/assign_055.phpt (revision 08b2ab22)
1--TEST--
2JIT ASSIGN: memory leak
3--INI--
4opcache.enable=1
5opcache.enable_cli=1
6opcache.file_update_protection=0
7opcache.protect_memory=1
8--FILE--
9<?php
10set_error_handler(function() {
11    (y);
12});
13$ret = new stdClass;
14try {
15    $ret = $y;
16} catch (y) {
17}
18?>
19--EXPECTF--
20Fatal error: Uncaught Error: Undefined constant "y" in %sassign_055.php:3
21Stack trace:
22#0 %s(%d): {closure:%s:%d}(2, 'Undefined varia...', '%s', 7)
23#1 {main}
24  thrown in %sassign_055.php on line 3
25