mirror of
https://github.com/php/php-src.git
synced 2024-12-15 21:05:51 +08:00
Merge branch 'PHP-8.3'
* PHP-8.3: Fixed inorrect QM_ASSIGN elimination
This commit is contained in:
commit
7fcbedd7df
@ -172,6 +172,7 @@ static void zend_optimize_block(zend_basic_block *block, zend_op_array *op_array
|
||||
&& opline->opcode != ZEND_SWITCH_LONG
|
||||
&& opline->opcode != ZEND_SWITCH_STRING
|
||||
&& opline->opcode != ZEND_MATCH
|
||||
&& opline->opcode != ZEND_MATCH_ERROR
|
||||
&& zend_optimizer_update_op1_const(op_array, opline, &c)) {
|
||||
VAR_SOURCE(op1) = NULL;
|
||||
if (opline->opcode != ZEND_JMP_NULL
|
||||
|
15
ext/opcache/tests/opt/block_pass_006.phpt
Normal file
15
ext/opcache/tests/opt/block_pass_006.phpt
Normal file
@ -0,0 +1,15 @@
|
||||
--TEST--
|
||||
Block Pass 006: Inorrect QM_ASSIGN elimination
|
||||
--INI--
|
||||
opcache.enable=1
|
||||
opcache.enable_cli=1
|
||||
opcache.optimization_level=-1
|
||||
--FILE--
|
||||
<?php
|
||||
match(match(''){c=>''}){}
|
||||
?>
|
||||
--EXPECTF--
|
||||
Fatal error: Uncaught Error: Undefined constant "c" in %sblock_pass_006.php:2
|
||||
Stack trace:
|
||||
#0 {main}
|
||||
thrown in %sblock_pass_006.php on line 2
|
Loading…
Reference in New Issue
Block a user