return HASH_KEY_IS_UNICODE;
case IS_DOUBLE:
+ *int_key = (long)Z_DVAL_P(retval);
+ zval_ptr_dtor(&retval);
+ return HASH_KEY_IS_LONG;
+
case IS_RESOURCE:
case IS_BOOL:
- case IS_LONG: {
- if (Z_TYPE_P(retval) == IS_DOUBLE) {
- *int_key = (long)Z_DVAL_P(retval);
- } else {
- *int_key = Z_LVAL_P(retval);
- }
- }
+ case IS_LONG:
+ *int_key = (long)Z_LVAL_P(retval);
zval_ptr_dtor(&retval);
return HASH_KEY_IS_LONG;
}
zend_free_op free_op1;
add_char_to_string(&EX_T(opline->result.u.var).tmp_var,
- GET_OP1_ZVAL_PTR(BP_VAR_NA),
- &opline->op2.u.constant);
+ GET_OP1_ZVAL_PTR(BP_VAR_NA),
+ &opline->op2.u.constant);
/* FREE_OP is missing intentionally here - we're always working on the same temporary variable */
ZEND_VM_NEXT_OPCODE();
}
zend_free_op free_op1;
add_string_to_string(&EX_T(opline->result.u.var).tmp_var,
- GET_OP1_ZVAL_PTR(BP_VAR_NA),
- &opline->op2.u.constant);
+ GET_OP1_ZVAL_PTR(BP_VAR_NA),
+ &opline->op2.u.constant);
/* FREE_OP is missing intentionally here - we're always working on the same temporary variable */
ZEND_VM_NEXT_OPCODE();
}
}
}
}
- ex = ex->prev_execute_data;
- } while (ex && ex->symbol_table == target_symbol_table);
+ ex = ex->prev_execute_data;
+ } while (ex && ex->symbol_table == target_symbol_table);
}
}
switch (Z_TYPE_P(offset)) {
case IS_DOUBLE:
+ index = (long) Z_DVAL_P(offset);
+ zend_hash_index_del(ht, index);
+ break;
case IS_RESOURCE:
case IS_BOOL:
case IS_LONG:
- if (Z_TYPE_P(offset) == IS_DOUBLE) {
- index = (long) Z_DVAL_P(offset);
- } else {
- index = Z_LVAL_P(offset);
- }
-
+ index = Z_LVAL_P(offset);
zend_hash_index_del(ht, index);
break;
case IS_STRING:
switch (Z_TYPE_P(offset)) {
case IS_DOUBLE:
+ index = (long) Z_DVAL_P(offset);
+ if (zend_hash_index_find(ht, index, (void **) &value) == SUCCESS) {
+ isset = 1;
+ }
+ break;
case IS_RESOURCE:
case IS_BOOL:
case IS_LONG:
- if (Z_TYPE_P(offset) == IS_DOUBLE) {
- index = (long) Z_DVAL_P(offset);
- } else {
- index = Z_LVAL_P(offset);
- }
+ index = Z_LVAL_P(offset);
if (zend_hash_index_find(ht, index, (void **) &value) == SUCCESS) {
isset = 1;
}