FREE_OP1_IF_VAR();
ZEND_VM_NEXT_OPCODE_CHECK_EXCEPTION();
} else {
- zend_class_entry *ce = Z_OBJCE_P(array_ptr);
- zend_object_iterator *iter = ce->get_iterator(ce, array_ptr, 0);
- zend_bool is_empty;
-
- if (UNEXPECTED(!iter) || UNEXPECTED(EG(exception))) {
- FREE_OP1();
- if (iter) {
- OBJ_RELEASE(&iter->std);
- }
- if (!EG(exception)) {
- zend_throw_exception_ex(NULL, 0, "Object of type %s did not create an Iterator", ZSTR_VAL(ce->name));
- }
- ZVAL_UNDEF(EX_VAR(opline->result.var));
- HANDLE_EXCEPTION();
- }
-
- iter->index = 0;
- if (iter->funcs->rewind) {
- iter->funcs->rewind(iter);
- if (UNEXPECTED(EG(exception) != NULL)) {
- OBJ_RELEASE(&iter->std);
- FREE_OP1();
- ZVAL_UNDEF(EX_VAR(opline->result.var));
- HANDLE_EXCEPTION();
- }
- }
-
- is_empty = iter->funcs->valid(iter) != SUCCESS;
-
- if (UNEXPECTED(EG(exception) != NULL)) {
- OBJ_RELEASE(&iter->std);
- FREE_OP1();
- ZVAL_UNDEF(EX_VAR(opline->result.var));
- HANDLE_EXCEPTION();
- }
- iter->index = -1; /* will be set to 0 before using next handler */
-
- ZVAL_OBJ(EX_VAR(opline->result.var), &iter->std);
- Z_FE_ITER_P(EX_VAR(opline->result.var)) = (uint32_t)-1;
+ zend_bool is_empty = zend_fe_reset_iterator(array_ptr, 0 OPLINE_CC);
FREE_OP1();
if (UNEXPECTED(EG(exception))) {
}
Z_FE_ITER_P(EX_VAR(opline->result.var)) = zend_hash_iterator_add(Z_ARRVAL_P(array_ptr), 0);
- if (OP1_TYPE == IS_VAR) {
- FREE_OP1_VAR_PTR();
- }
+ FREE_OP1_VAR_PTR();
ZEND_VM_NEXT_OPCODE();
} else if (OP1_TYPE != IS_CONST && EXPECTED(Z_TYPE_P(array_ptr) == IS_OBJECT)) {
if (!Z_OBJCE_P(array_ptr)->get_iterator) {
}
Z_FE_ITER_P(EX_VAR(opline->result.var)) = zend_hash_iterator_add(Z_OBJPROP_P(array_ptr), 0);
- if (OP1_TYPE == IS_VAR) {
- FREE_OP1_VAR_PTR();
- }
+ FREE_OP1_VAR_PTR();
ZEND_VM_NEXT_OPCODE_CHECK_EXCEPTION();
} else {
- zend_class_entry *ce = Z_OBJCE_P(array_ptr);
- zend_object_iterator *iter = ce->get_iterator(ce, array_ptr, 1);
- zend_bool is_empty;
-
- if (UNEXPECTED(!iter) || UNEXPECTED(EG(exception))) {
- if (OP1_TYPE == IS_VAR) {
- FREE_OP1_VAR_PTR();
- } else {
- FREE_OP1();
- }
- if (!EG(exception)) {
- zend_throw_exception_ex(NULL, 0, "Object of type %s did not create an Iterator", ZSTR_VAL(ce->name));
- }
- ZVAL_UNDEF(EX_VAR(opline->result.var));
- HANDLE_EXCEPTION();
- }
-
- iter->index = 0;
- if (iter->funcs->rewind) {
- iter->funcs->rewind(iter);
- if (UNEXPECTED(EG(exception) != NULL)) {
- OBJ_RELEASE(&iter->std);
- if (OP1_TYPE == IS_VAR) {
- FREE_OP1_VAR_PTR();
- } else {
- FREE_OP1();
- }
- ZVAL_UNDEF(EX_VAR(opline->result.var));
- HANDLE_EXCEPTION();
- }
- }
-
- is_empty = iter->funcs->valid(iter) != SUCCESS;
-
- if (UNEXPECTED(EG(exception) != NULL)) {
- OBJ_RELEASE(&iter->std);
- if (OP1_TYPE == IS_VAR) {
- FREE_OP1_VAR_PTR();
- } else {
- FREE_OP1();
- }
- ZVAL_UNDEF(EX_VAR(opline->result.var));
- HANDLE_EXCEPTION();
- }
- iter->index = -1; /* will be set to 0 before using next handler */
-
- ZVAL_OBJ(EX_VAR(opline->result.var), &iter->std);
- Z_FE_ITER_P(EX_VAR(opline->result.var)) = (uint32_t)-1;
+ zend_bool is_empty = zend_fe_reset_iterator(array_ptr, 1 OPLINE_CC);
if (OP1_TYPE == IS_VAR) {
FREE_OP1_VAR_PTR();
ZEND_VM_NEXT_OPCODE_CHECK_EXCEPTION();
} else {
- zend_class_entry *ce = Z_OBJCE_P(array_ptr);
- zend_object_iterator *iter = ce->get_iterator(ce, array_ptr, 0);
- zend_bool is_empty;
-
- if (UNEXPECTED(!iter) || UNEXPECTED(EG(exception))) {
-
- if (iter) {
- OBJ_RELEASE(&iter->std);
- }
- if (!EG(exception)) {
- zend_throw_exception_ex(NULL, 0, "Object of type %s did not create an Iterator", ZSTR_VAL(ce->name));
- }
- ZVAL_UNDEF(EX_VAR(opline->result.var));
- HANDLE_EXCEPTION();
- }
-
- iter->index = 0;
- if (iter->funcs->rewind) {
- iter->funcs->rewind(iter);
- if (UNEXPECTED(EG(exception) != NULL)) {
- OBJ_RELEASE(&iter->std);
-
- ZVAL_UNDEF(EX_VAR(opline->result.var));
- HANDLE_EXCEPTION();
- }
- }
-
- is_empty = iter->funcs->valid(iter) != SUCCESS;
-
- if (UNEXPECTED(EG(exception) != NULL)) {
- OBJ_RELEASE(&iter->std);
-
- ZVAL_UNDEF(EX_VAR(opline->result.var));
- HANDLE_EXCEPTION();
- }
- iter->index = -1; /* will be set to 0 before using next handler */
-
- ZVAL_OBJ(EX_VAR(opline->result.var), &iter->std);
- Z_FE_ITER_P(EX_VAR(opline->result.var)) = (uint32_t)-1;
+ zend_bool is_empty = zend_fe_reset_iterator(array_ptr, 0 OPLINE_CC);
if (UNEXPECTED(EG(exception))) {
HANDLE_EXCEPTION();
}
Z_FE_ITER_P(EX_VAR(opline->result.var)) = zend_hash_iterator_add(Z_ARRVAL_P(array_ptr), 0);
- if (IS_CONST == IS_VAR) {
-
- }
ZEND_VM_NEXT_OPCODE();
} else if (IS_CONST != IS_CONST && EXPECTED(Z_TYPE_P(array_ptr) == IS_OBJECT)) {
if (!Z_OBJCE_P(array_ptr)->get_iterator) {
}
Z_FE_ITER_P(EX_VAR(opline->result.var)) = zend_hash_iterator_add(Z_OBJPROP_P(array_ptr), 0);
- if (IS_CONST == IS_VAR) {
-
- }
ZEND_VM_NEXT_OPCODE_CHECK_EXCEPTION();
} else {
- zend_class_entry *ce = Z_OBJCE_P(array_ptr);
- zend_object_iterator *iter = ce->get_iterator(ce, array_ptr, 1);
- zend_bool is_empty;
-
- if (UNEXPECTED(!iter) || UNEXPECTED(EG(exception))) {
- if (IS_CONST == IS_VAR) {
-
- } else {
-
- }
- if (!EG(exception)) {
- zend_throw_exception_ex(NULL, 0, "Object of type %s did not create an Iterator", ZSTR_VAL(ce->name));
- }
- ZVAL_UNDEF(EX_VAR(opline->result.var));
- HANDLE_EXCEPTION();
- }
-
- iter->index = 0;
- if (iter->funcs->rewind) {
- iter->funcs->rewind(iter);
- if (UNEXPECTED(EG(exception) != NULL)) {
- OBJ_RELEASE(&iter->std);
- if (IS_CONST == IS_VAR) {
-
- } else {
-
- }
- ZVAL_UNDEF(EX_VAR(opline->result.var));
- HANDLE_EXCEPTION();
- }
- }
-
- is_empty = iter->funcs->valid(iter) != SUCCESS;
-
- if (UNEXPECTED(EG(exception) != NULL)) {
- OBJ_RELEASE(&iter->std);
- if (IS_CONST == IS_VAR) {
-
- } else {
-
- }
- ZVAL_UNDEF(EX_VAR(opline->result.var));
- HANDLE_EXCEPTION();
- }
- iter->index = -1; /* will be set to 0 before using next handler */
-
- ZVAL_OBJ(EX_VAR(opline->result.var), &iter->std);
- Z_FE_ITER_P(EX_VAR(opline->result.var)) = (uint32_t)-1;
+ zend_bool is_empty = zend_fe_reset_iterator(array_ptr, 1 OPLINE_CC);
if (IS_CONST == IS_VAR) {
ZEND_VM_NEXT_OPCODE_CHECK_EXCEPTION();
} else {
- zend_class_entry *ce = Z_OBJCE_P(array_ptr);
- zend_object_iterator *iter = ce->get_iterator(ce, array_ptr, 0);
- zend_bool is_empty;
-
- if (UNEXPECTED(!iter) || UNEXPECTED(EG(exception))) {
- zval_ptr_dtor_nogc(free_op1);
- if (iter) {
- OBJ_RELEASE(&iter->std);
- }
- if (!EG(exception)) {
- zend_throw_exception_ex(NULL, 0, "Object of type %s did not create an Iterator", ZSTR_VAL(ce->name));
- }
- ZVAL_UNDEF(EX_VAR(opline->result.var));
- HANDLE_EXCEPTION();
- }
-
- iter->index = 0;
- if (iter->funcs->rewind) {
- iter->funcs->rewind(iter);
- if (UNEXPECTED(EG(exception) != NULL)) {
- OBJ_RELEASE(&iter->std);
- zval_ptr_dtor_nogc(free_op1);
- ZVAL_UNDEF(EX_VAR(opline->result.var));
- HANDLE_EXCEPTION();
- }
- }
-
- is_empty = iter->funcs->valid(iter) != SUCCESS;
-
- if (UNEXPECTED(EG(exception) != NULL)) {
- OBJ_RELEASE(&iter->std);
- zval_ptr_dtor_nogc(free_op1);
- ZVAL_UNDEF(EX_VAR(opline->result.var));
- HANDLE_EXCEPTION();
- }
- iter->index = -1; /* will be set to 0 before using next handler */
-
- ZVAL_OBJ(EX_VAR(opline->result.var), &iter->std);
- Z_FE_ITER_P(EX_VAR(opline->result.var)) = (uint32_t)-1;
+ zend_bool is_empty = zend_fe_reset_iterator(array_ptr, 0 OPLINE_CC);
zval_ptr_dtor_nogc(free_op1);
if (UNEXPECTED(EG(exception))) {
}
Z_FE_ITER_P(EX_VAR(opline->result.var)) = zend_hash_iterator_add(Z_ARRVAL_P(array_ptr), 0);
- if (IS_TMP_VAR == IS_VAR) {
-
- }
ZEND_VM_NEXT_OPCODE();
} else if (IS_TMP_VAR != IS_CONST && EXPECTED(Z_TYPE_P(array_ptr) == IS_OBJECT)) {
if (!Z_OBJCE_P(array_ptr)->get_iterator) {
}
Z_FE_ITER_P(EX_VAR(opline->result.var)) = zend_hash_iterator_add(Z_OBJPROP_P(array_ptr), 0);
- if (IS_TMP_VAR == IS_VAR) {
-
- }
ZEND_VM_NEXT_OPCODE_CHECK_EXCEPTION();
} else {
- zend_class_entry *ce = Z_OBJCE_P(array_ptr);
- zend_object_iterator *iter = ce->get_iterator(ce, array_ptr, 1);
- zend_bool is_empty;
-
- if (UNEXPECTED(!iter) || UNEXPECTED(EG(exception))) {
- if (IS_TMP_VAR == IS_VAR) {
-
- } else {
- zval_ptr_dtor_nogc(free_op1);
- }
- if (!EG(exception)) {
- zend_throw_exception_ex(NULL, 0, "Object of type %s did not create an Iterator", ZSTR_VAL(ce->name));
- }
- ZVAL_UNDEF(EX_VAR(opline->result.var));
- HANDLE_EXCEPTION();
- }
-
- iter->index = 0;
- if (iter->funcs->rewind) {
- iter->funcs->rewind(iter);
- if (UNEXPECTED(EG(exception) != NULL)) {
- OBJ_RELEASE(&iter->std);
- if (IS_TMP_VAR == IS_VAR) {
-
- } else {
- zval_ptr_dtor_nogc(free_op1);
- }
- ZVAL_UNDEF(EX_VAR(opline->result.var));
- HANDLE_EXCEPTION();
- }
- }
-
- is_empty = iter->funcs->valid(iter) != SUCCESS;
-
- if (UNEXPECTED(EG(exception) != NULL)) {
- OBJ_RELEASE(&iter->std);
- if (IS_TMP_VAR == IS_VAR) {
-
- } else {
- zval_ptr_dtor_nogc(free_op1);
- }
- ZVAL_UNDEF(EX_VAR(opline->result.var));
- HANDLE_EXCEPTION();
- }
- iter->index = -1; /* will be set to 0 before using next handler */
-
- ZVAL_OBJ(EX_VAR(opline->result.var), &iter->std);
- Z_FE_ITER_P(EX_VAR(opline->result.var)) = (uint32_t)-1;
+ zend_bool is_empty = zend_fe_reset_iterator(array_ptr, 1 OPLINE_CC);
if (IS_TMP_VAR == IS_VAR) {
zval_ptr_dtor_nogc(free_op1);
ZEND_VM_NEXT_OPCODE_CHECK_EXCEPTION();
} else {
- zend_class_entry *ce = Z_OBJCE_P(array_ptr);
- zend_object_iterator *iter = ce->get_iterator(ce, array_ptr, 0);
- zend_bool is_empty;
-
- if (UNEXPECTED(!iter) || UNEXPECTED(EG(exception))) {
- zval_ptr_dtor_nogc(free_op1);
- if (iter) {
- OBJ_RELEASE(&iter->std);
- }
- if (!EG(exception)) {
- zend_throw_exception_ex(NULL, 0, "Object of type %s did not create an Iterator", ZSTR_VAL(ce->name));
- }
- ZVAL_UNDEF(EX_VAR(opline->result.var));
- HANDLE_EXCEPTION();
- }
-
- iter->index = 0;
- if (iter->funcs->rewind) {
- iter->funcs->rewind(iter);
- if (UNEXPECTED(EG(exception) != NULL)) {
- OBJ_RELEASE(&iter->std);
- zval_ptr_dtor_nogc(free_op1);
- ZVAL_UNDEF(EX_VAR(opline->result.var));
- HANDLE_EXCEPTION();
- }
- }
-
- is_empty = iter->funcs->valid(iter) != SUCCESS;
-
- if (UNEXPECTED(EG(exception) != NULL)) {
- OBJ_RELEASE(&iter->std);
- zval_ptr_dtor_nogc(free_op1);
- ZVAL_UNDEF(EX_VAR(opline->result.var));
- HANDLE_EXCEPTION();
- }
- iter->index = -1; /* will be set to 0 before using next handler */
-
- ZVAL_OBJ(EX_VAR(opline->result.var), &iter->std);
- Z_FE_ITER_P(EX_VAR(opline->result.var)) = (uint32_t)-1;
+ zend_bool is_empty = zend_fe_reset_iterator(array_ptr, 0 OPLINE_CC);
zval_ptr_dtor_nogc(free_op1);
if (UNEXPECTED(EG(exception))) {
}
Z_FE_ITER_P(EX_VAR(opline->result.var)) = zend_hash_iterator_add(Z_ARRVAL_P(array_ptr), 0);
- if (IS_VAR == IS_VAR) {
- if (UNEXPECTED(free_op1)) {zval_ptr_dtor_nogc(free_op1);};
- }
+ if (UNEXPECTED(free_op1)) {zval_ptr_dtor_nogc(free_op1);};
ZEND_VM_NEXT_OPCODE();
} else if (IS_VAR != IS_CONST && EXPECTED(Z_TYPE_P(array_ptr) == IS_OBJECT)) {
if (!Z_OBJCE_P(array_ptr)->get_iterator) {
}
Z_FE_ITER_P(EX_VAR(opline->result.var)) = zend_hash_iterator_add(Z_OBJPROP_P(array_ptr), 0);
- if (IS_VAR == IS_VAR) {
- if (UNEXPECTED(free_op1)) {zval_ptr_dtor_nogc(free_op1);};
- }
+ if (UNEXPECTED(free_op1)) {zval_ptr_dtor_nogc(free_op1);};
ZEND_VM_NEXT_OPCODE_CHECK_EXCEPTION();
} else {
- zend_class_entry *ce = Z_OBJCE_P(array_ptr);
- zend_object_iterator *iter = ce->get_iterator(ce, array_ptr, 1);
- zend_bool is_empty;
-
- if (UNEXPECTED(!iter) || UNEXPECTED(EG(exception))) {
- if (IS_VAR == IS_VAR) {
- if (UNEXPECTED(free_op1)) {zval_ptr_dtor_nogc(free_op1);};
- } else {
- zval_ptr_dtor_nogc(free_op1);
- }
- if (!EG(exception)) {
- zend_throw_exception_ex(NULL, 0, "Object of type %s did not create an Iterator", ZSTR_VAL(ce->name));
- }
- ZVAL_UNDEF(EX_VAR(opline->result.var));
- HANDLE_EXCEPTION();
- }
-
- iter->index = 0;
- if (iter->funcs->rewind) {
- iter->funcs->rewind(iter);
- if (UNEXPECTED(EG(exception) != NULL)) {
- OBJ_RELEASE(&iter->std);
- if (IS_VAR == IS_VAR) {
- if (UNEXPECTED(free_op1)) {zval_ptr_dtor_nogc(free_op1);};
- } else {
- zval_ptr_dtor_nogc(free_op1);
- }
- ZVAL_UNDEF(EX_VAR(opline->result.var));
- HANDLE_EXCEPTION();
- }
- }
-
- is_empty = iter->funcs->valid(iter) != SUCCESS;
-
- if (UNEXPECTED(EG(exception) != NULL)) {
- OBJ_RELEASE(&iter->std);
- if (IS_VAR == IS_VAR) {
- if (UNEXPECTED(free_op1)) {zval_ptr_dtor_nogc(free_op1);};
- } else {
- zval_ptr_dtor_nogc(free_op1);
- }
- ZVAL_UNDEF(EX_VAR(opline->result.var));
- HANDLE_EXCEPTION();
- }
- iter->index = -1; /* will be set to 0 before using next handler */
-
- ZVAL_OBJ(EX_VAR(opline->result.var), &iter->std);
- Z_FE_ITER_P(EX_VAR(opline->result.var)) = (uint32_t)-1;
+ zend_bool is_empty = zend_fe_reset_iterator(array_ptr, 1 OPLINE_CC);
if (IS_VAR == IS_VAR) {
if (UNEXPECTED(free_op1)) {zval_ptr_dtor_nogc(free_op1);};
ZEND_VM_NEXT_OPCODE_CHECK_EXCEPTION();
} else {
- zend_class_entry *ce = Z_OBJCE_P(array_ptr);
- zend_object_iterator *iter = ce->get_iterator(ce, array_ptr, 0);
- zend_bool is_empty;
-
- if (UNEXPECTED(!iter) || UNEXPECTED(EG(exception))) {
-
- if (iter) {
- OBJ_RELEASE(&iter->std);
- }
- if (!EG(exception)) {
- zend_throw_exception_ex(NULL, 0, "Object of type %s did not create an Iterator", ZSTR_VAL(ce->name));
- }
- ZVAL_UNDEF(EX_VAR(opline->result.var));
- HANDLE_EXCEPTION();
- }
-
- iter->index = 0;
- if (iter->funcs->rewind) {
- iter->funcs->rewind(iter);
- if (UNEXPECTED(EG(exception) != NULL)) {
- OBJ_RELEASE(&iter->std);
-
- ZVAL_UNDEF(EX_VAR(opline->result.var));
- HANDLE_EXCEPTION();
- }
- }
-
- is_empty = iter->funcs->valid(iter) != SUCCESS;
-
- if (UNEXPECTED(EG(exception) != NULL)) {
- OBJ_RELEASE(&iter->std);
-
- ZVAL_UNDEF(EX_VAR(opline->result.var));
- HANDLE_EXCEPTION();
- }
- iter->index = -1; /* will be set to 0 before using next handler */
-
- ZVAL_OBJ(EX_VAR(opline->result.var), &iter->std);
- Z_FE_ITER_P(EX_VAR(opline->result.var)) = (uint32_t)-1;
+ zend_bool is_empty = zend_fe_reset_iterator(array_ptr, 0 OPLINE_CC);
if (UNEXPECTED(EG(exception))) {
HANDLE_EXCEPTION();
}
Z_FE_ITER_P(EX_VAR(opline->result.var)) = zend_hash_iterator_add(Z_ARRVAL_P(array_ptr), 0);
- if (IS_CV == IS_VAR) {
-
- }
ZEND_VM_NEXT_OPCODE();
} else if (IS_CV != IS_CONST && EXPECTED(Z_TYPE_P(array_ptr) == IS_OBJECT)) {
if (!Z_OBJCE_P(array_ptr)->get_iterator) {
}
Z_FE_ITER_P(EX_VAR(opline->result.var)) = zend_hash_iterator_add(Z_OBJPROP_P(array_ptr), 0);
- if (IS_CV == IS_VAR) {
-
- }
ZEND_VM_NEXT_OPCODE_CHECK_EXCEPTION();
} else {
- zend_class_entry *ce = Z_OBJCE_P(array_ptr);
- zend_object_iterator *iter = ce->get_iterator(ce, array_ptr, 1);
- zend_bool is_empty;
-
- if (UNEXPECTED(!iter) || UNEXPECTED(EG(exception))) {
- if (IS_CV == IS_VAR) {
-
- } else {
-
- }
- if (!EG(exception)) {
- zend_throw_exception_ex(NULL, 0, "Object of type %s did not create an Iterator", ZSTR_VAL(ce->name));
- }
- ZVAL_UNDEF(EX_VAR(opline->result.var));
- HANDLE_EXCEPTION();
- }
-
- iter->index = 0;
- if (iter->funcs->rewind) {
- iter->funcs->rewind(iter);
- if (UNEXPECTED(EG(exception) != NULL)) {
- OBJ_RELEASE(&iter->std);
- if (IS_CV == IS_VAR) {
-
- } else {
-
- }
- ZVAL_UNDEF(EX_VAR(opline->result.var));
- HANDLE_EXCEPTION();
- }
- }
-
- is_empty = iter->funcs->valid(iter) != SUCCESS;
-
- if (UNEXPECTED(EG(exception) != NULL)) {
- OBJ_RELEASE(&iter->std);
- if (IS_CV == IS_VAR) {
-
- } else {
-
- }
- ZVAL_UNDEF(EX_VAR(opline->result.var));
- HANDLE_EXCEPTION();
- }
- iter->index = -1; /* will be set to 0 before using next handler */
-
- ZVAL_OBJ(EX_VAR(opline->result.var), &iter->std);
- Z_FE_ITER_P(EX_VAR(opline->result.var)) = (uint32_t)-1;
+ zend_bool is_empty = zend_fe_reset_iterator(array_ptr, 1 OPLINE_CC);
if (IS_CV == IS_VAR) {