mirror of
https://github.com/php/php-src.git
synced 2025-01-24 04:33:39 +08:00
Merge branch 'PHP-8.1'
* PHP-8.1: Fix type inference
This commit is contained in:
commit
387c78a41f
@ -2703,9 +2703,6 @@ static zend_always_inline zend_result _zend_update_type_info(
|
||||
tmp |= MAY_BE_NULL|MAY_BE_FALSE|MAY_BE_TRUE|MAY_BE_LONG|MAY_BE_DOUBLE|MAY_BE_STRING;
|
||||
}
|
||||
}
|
||||
if (t1 & MAY_BE_OBJECT) {
|
||||
tmp |= MAY_BE_REF;
|
||||
}
|
||||
tmp |= MAY_BE_RC1 | MAY_BE_RCN;
|
||||
UPDATE_SSA_TYPE(tmp, ssa_op->result_def);
|
||||
}
|
||||
|
18
ext/opcache/tests/jit/assign_dim_008.phpt
Normal file
18
ext/opcache/tests/jit/assign_dim_008.phpt
Normal file
@ -0,0 +1,18 @@
|
||||
--TEST--
|
||||
JIT ASSIGN_DIM: 008
|
||||
--INI--
|
||||
opcache.enable=1
|
||||
opcache.enable_cli=1
|
||||
opcache.file_update_protection=0
|
||||
opcache.jit_buffer_size=1M
|
||||
--FILE--
|
||||
<?php
|
||||
function(int $a) {
|
||||
$arr = $a[] = (y);
|
||||
$arr = y;
|
||||
$c = $y = $arr[] = y($c);
|
||||
}
|
||||
?>
|
||||
DONE
|
||||
--EXPECT--
|
||||
DONE
|
Loading…
Reference in New Issue
Block a user