From cbb9ee8f5b1976c19fd0070f242cd8c798083bd5 Mon Sep 17 00:00:00 2001 From: Dmitry Stogov Date: Wed, 13 Aug 2025 15:58:04 +0300 Subject: [PATCH] Added test for PR #19458 Thanks to @DanielEScherzer --- ext/opcache/tests/jit/assign_obj_006.phpt | 37 +++++++++++++++++++++++ 1 file changed, 37 insertions(+) create mode 100644 ext/opcache/tests/jit/assign_obj_006.phpt diff --git a/ext/opcache/tests/jit/assign_obj_006.phpt b/ext/opcache/tests/jit/assign_obj_006.phpt new file mode 100644 index 00000000000..a48299f0401 --- /dev/null +++ b/ext/opcache/tests/jit/assign_obj_006.phpt @@ -0,0 +1,37 @@ +--TEST-- +JIT ASSIGN_OBJ: violation of dominance +--INI-- +opcache.enable=1 +opcache.enable_cli=1 +opcache.file_update_protection=0 +opcache.jit_buffer_size=1M +--FILE-- +value = $value['value']; + } + return $item; + }, + null, + CacheItem::class); + return $test($value); +} + +$values = [['value'=>'str'], ['value'=>'str'], ['value'=>42]]; +$n = count($values); + +for ($i = 0; $i < $n; $i++) { + test($values[$i]); +} +?> +OK +--EXPECT-- +OK