mirror of
https://github.com/php/php-src.git
synced 2026-04-20 22:41:20 +02:00
* PHP-8.0: JIT x86: Fixed register clobbering in code produced for "$x[$y] %= $z". Fix #81420: ZipArchive::extractTo extracts outside of destination
37 lines
516 B
PHP
37 lines
516 B
PHP
--TEST--
|
|
JIT MOD: 003
|
|
--INI--
|
|
opcache.enable=1
|
|
opcache.enable_cli=1
|
|
opcache.file_update_protection=0
|
|
opcache.jit_buffer_size=1M
|
|
opcache.protect_memory=1
|
|
opcache.jit=function
|
|
--EXTENSIONS--
|
|
opcache
|
|
--FILE--
|
|
<?php
|
|
class Test {
|
|
public $prop = 0;
|
|
}
|
|
function test1($test) {
|
|
$test[0] %= 3;
|
|
return $test;
|
|
}
|
|
function test2($test) {
|
|
$test->prop %= 3;
|
|
return $test;
|
|
}
|
|
var_dump(test1([0]));
|
|
var_dump(test2(new Test));
|
|
?>
|
|
--EXPECT--
|
|
array(1) {
|
|
[0]=>
|
|
int(0)
|
|
}
|
|
object(Test)#1 (1) {
|
|
["prop"]=>
|
|
int(0)
|
|
}
|