Created
June 11, 2021 08:26
-
-
Save dstogov/523e5541135212a2811899ab7718218e to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| diff --git a/Zend/Optimizer/zend_inference.c b/Zend/Optimizer/zend_inference.c | |
| index bee54586fc..d8f82e87b2 100644 | |
| --- a/Zend/Optimizer/zend_inference.c | |
| +++ b/Zend/Optimizer/zend_inference.c | |
| @@ -2393,13 +2393,13 @@ static zend_always_inline int _zend_update_type_info( | |
| if (!(t1 & (MAY_BE_ANY|MAY_BE_UNDEF|MAY_BE_CLASS)) | |
| || !(t2 & (MAY_BE_ANY|MAY_BE_UNDEF|MAY_BE_CLASS))) { | |
| tmp = 0; | |
| - if (ssa_op->result_def >= 0) { | |
| + if (ssa_op->result_def >= 0 && !(ssa_var_info[ssa_op->result_def].type & MAY_BE_REF)) { | |
| UPDATE_SSA_TYPE(tmp, ssa_op->result_def); | |
| } | |
| - if (ssa_op->op1_def >= 0) { | |
| + if (ssa_op->op1_def >= 0 && !(ssa_var_info[ssa_op->op1_def].type & MAY_BE_REF)) { | |
| UPDATE_SSA_TYPE(tmp, ssa_op->op1_def); | |
| } | |
| - if (ssa_op->op2_def >= 0) { | |
| + if (ssa_op->op2_def >= 0 && !(ssa_var_info[ssa_op->op2_def].type & MAY_BE_REF)) { | |
| UPDATE_SSA_TYPE(tmp, ssa_op->op2_def); | |
| } | |
| return 1; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment