com php-src: Use better check: Zend/zend_vm_def.h Zend/ zend_vm_execute.h

From: Date: Thu, 26 Jul 2018 11:13:33 +0000
Subject: com php-src: Use better check: Zend/zend_vm_def.h Zend/ zend_vm_execute.h
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-102684@lists.php.net to get a copy of this message
Commit: f374e9376203a0e9c24e14409cdd00446936b4a6 Author: Dmitry Stogov <dmitry@zend.com> Thu, 26 Jul 2018 14:13:33 +0300 Parents: 562150906acc01736e20bf4f05ee746d17712874 Branches: master Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=f374e9376203a0e9c24e14409cdd00446936b4a6 Log: Use better check Changed paths: M Zend/zend_vm_def.h M Zend/zend_vm_execute.h Diff: diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h index d6837c2..286d58f 100644 --- a/Zend/zend_vm_def.h +++ b/Zend/zend_vm_def.h @@ -5841,7 +5841,7 @@ ZEND_VM_C_LABEL(fe_fetch_r_exit): p++; } Z_FE_POS_P(array) = pos + 1; - if (opline->result_type & (IS_TMP_VAR|IS_CV)) { + if (RETURN_VALUE_USED(opline)) { if (!p->key) { ZVAL_LONG(EX_VAR(opline->result.var), p->h); } else { @@ -5881,7 +5881,7 @@ ZEND_VM_C_LABEL(fe_fetch_r_exit): pos++; p++; } - if (opline->result_type & (IS_TMP_VAR|IS_CV)) { + if (RETURN_VALUE_USED(opline)) { if (UNEXPECTED(!p->key)) { ZVAL_LONG(EX_VAR(opline->result.var), p->h); } else if (ZSTR_VAL(p->key)[0]) { @@ -5922,7 +5922,7 @@ ZEND_VM_C_LABEL(fe_fetch_r_exit): /* failure in get_current_data */ ZEND_VM_C_GOTO(fe_fetch_r_exit); } - if (opline->result_type & (IS_TMP_VAR|IS_CV)) { + if (RETURN_VALUE_USED(opline)) { if (iter->funcs->get_current_key) { iter->funcs->get_current_key(iter, EX_VAR(opline->result.var)); if (UNEXPECTED(EG(exception) != NULL)) { @@ -5991,7 +5991,7 @@ ZEND_VM_HANDLER(126, ZEND_FE_FETCH_RW, VAR, ANY, JMP_ADDR) pos++; p++; } - if (opline->result_type & (IS_TMP_VAR|IS_CV)) { + if (RETURN_VALUE_USED(opline)) { if (!p->key) { ZVAL_LONG(EX_VAR(opline->result.var), p->h); } else { @@ -6031,7 +6031,7 @@ ZEND_VM_HANDLER(126, ZEND_FE_FETCH_RW, VAR, ANY, JMP_ADDR) pos++; p++; } - if (opline->result_type & (IS_TMP_VAR|IS_CV)) { + if (RETURN_VALUE_USED(opline)) { if (UNEXPECTED(!p->key)) { ZVAL_LONG(EX_VAR(opline->result.var), p->h); } else if (ZSTR_VAL(p->key)[0]) { @@ -6072,7 +6072,7 @@ ZEND_VM_HANDLER(126, ZEND_FE_FETCH_RW, VAR, ANY, JMP_ADDR) /* failure in get_current_data */ ZEND_VM_C_GOTO(fe_fetch_w_exit); } - if (opline->result_type & (IS_TMP_VAR|IS_CV)) { + if (RETURN_VALUE_USED(opline)) { if (iter->funcs->get_current_key) { iter->funcs->get_current_key(iter, EX_VAR(opline->result.var)); if (UNEXPECTED(EG(exception) != NULL)) { diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h index 983e090...38f9885 100644 --- a/Zend/zend_vm_execute.h +++ b/Zend/zend_vm_execute..h @@ -21426,7 +21426,7 @@ fe_fetch_r_exit: p++; } Z_FE_POS_P(array) = pos + 1; - if (opline->result_type & (IS_TMP_VAR|IS_CV)) { + if (RETURN_VALUE_USED(opline)) { if (!p->key) { ZVAL_LONG(EX_VAR(opline->result.var), p->h); } else { @@ -21466,7 +21466,7 @@ fe_fetch_r_exit: pos++; p++; } - if (opline->result_type & (IS_TMP_VAR|IS_CV)) { + if (RETURN_VALUE_USED(opline)) { if (UNEXPECTED(!p->key)) { ZVAL_LONG(EX_VAR(opline->result.var), p->h); } else if (ZSTR_VAL(p->key)[0]) { @@ -21507,7 +21507,7 @@ fe_fetch_r_exit: /* failure in get_current_data */ goto fe_fetch_r_exit; } - if (opline->result_type & (IS_TMP_VAR|IS_CV)) { + if (RETURN_VALUE_USED(opline)) { if (iter->funcs->get_current_key) { iter->funcs->get_current_key(iter, EX_VAR(opline->result.var)); if (UNEXPECTED(EG(exception) != NULL)) { @@ -21576,7 +21576,7 @@ static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL ZEND_FE_FETCH_RW_SPEC_VAR_HANDLER(Z pos++; p++; } - if (opline->result_type & (IS_TMP_VAR|IS_CV)) { + if (RETURN_VALUE_USED(opline)) { if (!p->key) { ZVAL_LONG(EX_VAR(opline->result.var), p->h); } else { @@ -21616,7 +21616,7 @@ static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL ZEND_FE_FETCH_RW_SPEC_VAR_HANDLER(Z pos++; p++; } - if (opline->result_type & (IS_TMP_VAR|IS_CV)) { + if (RETURN_VALUE_USED(opline)) { if (UNEXPECTED(!p->key)) { ZVAL_LONG(EX_VAR(opline->result.var), p->h); } else if (ZSTR_VAL(p->key)[0]) { @@ -21657,7 +21657,7 @@ static ZEND_OPCODE_HANDLER_RET ZEND_FASTCALL ZEND_FE_FETCH_RW_SPEC_VAR_HANDLER(Z /* failure in get_current_data */ goto fe_fetch_w_exit; } - if (opline->result_type & (IS_TMP_VAR|IS_CV)) { + if (RETURN_VALUE_USED(opline)) { if (iter->funcs->get_current_key) { iter->funcs->get_current_key(iter, EX_VAR(opline->result.var)); if (UNEXPECTED(EG(exception) != NULL)) {

« previous php.cvs (#102684) next »