summaryrefslogtreecommitdiff
path: root/Zend/zend_execute.c
diff options
context:
space:
mode:
authorZeev Suraski <zeev@php.net>1999-07-09 17:44:41 +0000
committerZeev Suraski <zeev@php.net>1999-07-09 17:44:41 +0000
commit5f62c347c73300d5903a110c863be45b3b96c9f8 (patch)
tree352a88767f9131214ee23b909e0bb7ac29ea31f0 /Zend/zend_execute.c
parent3a9cb0220ce35e82065e92c4477b81373ab3e234 (diff)
downloadphp-git-5f62c347c73300d5903a110c863be45b3b96c9f8.tar.gz
Step 2:
Rename is_ref to EA
Diffstat (limited to 'Zend/zend_execute.c')
-rw-r--r--Zend/zend_execute.c64
1 files changed, 32 insertions, 32 deletions
diff --git a/Zend/zend_execute.c b/Zend/zend_execute.c
index 1254206539..366226b8a6 100644
--- a/Zend/zend_execute.c
+++ b/Zend/zend_execute.c
@@ -95,7 +95,7 @@ static inline zval *_get_zval_ptr(znode *node, temp_variable *Ts, int *should_fr
case IS_OVERLOADED_OBJECT:
Ts[node->u.var].tmp_var = get_overloaded_property(ELS_C);
Ts[node->u.var].tmp_var.refcount=1;
- Ts[node->u.var].tmp_var.is_ref=1;
+ Ts[node->u.var].tmp_var.EA=1;
return &Ts[node->u.var].tmp_var;
break;
case IS_STRING_OFFSET: {
@@ -114,7 +114,7 @@ static inline zval *_get_zval_ptr(znode *node, temp_variable *Ts, int *should_fr
}
zval_ptr_dtor(&str);
T->tmp_var.refcount=1;
- T->tmp_var.is_ref=1;
+ T->tmp_var.EA=1;
T->tmp_var.type = IS_STRING;
return &T->tmp_var;
}
@@ -264,14 +264,14 @@ static inline void zend_assign_to_variable(znode *result, znode *op1, znode *op2
return;
}
- if (variable_ptr->is_ref) {
+ if (variable_ptr->EA) {
if (variable_ptr!=value) {
short refcount=variable_ptr->refcount;
zendi_zval_dtor(*variable_ptr);
*variable_ptr = *value;
variable_ptr->refcount = refcount;
- variable_ptr->is_ref=1;
+ variable_ptr->EA=1;
if (type!=IS_TMP_VAR) {
zendi_zval_copy_ctor(*variable_ptr);
}
@@ -284,7 +284,7 @@ static inline void zend_assign_to_variable(znode *result, znode *op1, znode *op2
case IS_CONST:
if (variable_ptr==value) {
variable_ptr->refcount++;
- } else if (value->is_ref) {
+ } else if (value->EA) {
zval tmp = *value;
tmp = *value;
@@ -309,7 +309,7 @@ static inline void zend_assign_to_variable(znode *result, znode *op1, znode *op2
switch (type) {
case IS_VAR:
case IS_CONST:
- if (value->is_ref) {
+ if (value->EA) {
variable_ptr = *variable_ptr_ptr = (zval *) emalloc(sizeof(zval));
*variable_ptr = *value;
zval_copy_ctor(variable_ptr);
@@ -326,7 +326,7 @@ static inline void zend_assign_to_variable(znode *result, znode *op1, znode *op2
break;
}
}
- (*variable_ptr_ptr)->is_ref=0;
+ (*variable_ptr_ptr)->EA=0;
}
if (result) {
Ts[result->u.var].var = variable_ptr_ptr;
@@ -558,11 +558,11 @@ static inline void zend_fetch_dimension_address(znode *result, znode *op1, znode
switch (type) {
case BP_VAR_RW:
case BP_VAR_W:
- if (!container->is_ref) {
+ if (!container->EA) {
container->refcount--;
if (container->refcount>0) {
container = *container_ptr = (zval *) emalloc(sizeof(zval));
- container->is_ref=0;
+ container->EA=0;
}
container->refcount=1;
}
@@ -573,13 +573,13 @@ static inline void zend_fetch_dimension_address(znode *result, znode *op1, znode
switch (container->type) {
case IS_ARRAY:
- if ((type==BP_VAR_W || type==BP_VAR_RW) && container->refcount>1 && !container->is_ref) {
+ if ((type==BP_VAR_W || type==BP_VAR_RW) && container->refcount>1 && !container->EA) {
container->refcount--;
*container_ptr = (zval *) emalloc(sizeof(zval));
**container_ptr = *container;
container = *container_ptr;
container->refcount=1;
- container->is_ref=0;
+ container->EA=0;
zendi_zval_copy_ctor(*container);
}
if (op2->op_type == IS_UNUSED) {
@@ -725,11 +725,11 @@ static inline void zend_fetch_property_address(znode *result, znode *op1, znode
switch (type) {
case BP_VAR_RW:
case BP_VAR_W:
- if (!container->is_ref) {
+ if (!container->EA) {
container->refcount--;
if (container->refcount>0) {
container = *container_ptr = (zval *) emalloc(sizeof(zval));
- container->is_ref=0;
+ container->EA=0;
}
container->refcount=1;
}
@@ -754,13 +754,13 @@ static inline void zend_fetch_property_address(znode *result, znode *op1, znode
}
- if ((type==BP_VAR_W || type==BP_VAR_RW) && container->refcount>1 && !container->is_ref) {
+ if ((type==BP_VAR_W || type==BP_VAR_RW) && container->refcount>1 && !container->EA) {
container->refcount--;
*container_ptr = (zval *) emalloc(sizeof(zval));
**container_ptr = *container;
container = *container_ptr;
container->refcount=1;
- container->is_ref=0;
+ container->EA=0;
zendi_zval_copy_ctor(*container);
}
INC_AI_COUNT(result);
@@ -856,7 +856,7 @@ void execute(zend_op_array *op_array ELS_DC)
zval *globals = (zval *) emalloc(sizeof(zval));
globals->refcount=1;
- globals->is_ref=1;
+ globals->EA=1;
globals->type = IS_ARRAY;
globals->value.ht = &EG(symbol_table);
if (zend_hash_add(EG(active_symbol_table), "GLOBALS", sizeof("GLOBALS"), &globals, sizeof(zval *), NULL)==FAILURE) {
@@ -974,7 +974,7 @@ binary_assign_op_addr: {
opline++;
continue;
}
- if (!(*var_ptr)->is_ref) {
+ if (!(*var_ptr)->EA) {
if ((*var_ptr)->refcount>1) {
zval *orig_var=*var_ptr;
@@ -1017,7 +1017,7 @@ binary_assign_op_addr: {
zendi_zval_copy_ctor(Ts[opline->result.u.var].tmp_var);
break;
}
- if (!(*var_ptr)->is_ref) {
+ if (!(*var_ptr)->EA) {
if ((*var_ptr)->refcount>1) {
zval *orig_var = *var_ptr;
@@ -1359,7 +1359,7 @@ do_fcall_common:
var_uninit(dummy);
dummy->refcount=1;
- dummy->is_ref=0;
+ dummy->EA=0;
zend_hash_update_ptr(function_state.function_symbol_table, "this", sizeof("this"), dummy, sizeof(zval *), (void **) &this_ptr);
zend_assign_to_variable_reference(NULL, this_ptr, object_ptr, NULL ELS_CC);
object_ptr = NULL;
@@ -1420,7 +1420,7 @@ do_fcall_common:
*valptr = Ts[opline->op1.u.var].tmp_var;
valptr->refcount=1;
- valptr->is_ref=0;
+ valptr->EA=0;
zend_ptr_stack_push(&EG(argument_stack), valptr);
}
break;
@@ -1439,13 +1439,13 @@ do_fcall_common:
varptr = (zval *) emalloc(sizeof(zval));
var_uninit(varptr);
varptr->refcount=0;
- varptr->is_ref=0;
- } else if (varptr->is_ref) {
+ varptr->EA=0;
+ } else if (varptr->EA) {
zval *original_var = varptr;
varptr = (zval *) emalloc(sizeof(zval));
*varptr = *original_var;
- varptr->is_ref = 0;
+ varptr->EA = 0;
varptr->refcount = 0;
zval_copy_ctor(varptr);
}
@@ -1459,7 +1459,7 @@ send_by_ref:
zval **varptr_ptr = get_zval_ptr_ptr(&opline->op1, Ts, BP_VAR_W);
zval *varptr = *varptr_ptr;
- if (!varptr->is_ref) {
+ if (!varptr->EA) {
/* code to break away this variable */
if (varptr->refcount>1) {
varptr->refcount--;
@@ -1469,7 +1469,7 @@ send_by_ref:
varptr->refcount = 1;
zval_copy_ctor(varptr);
}
- varptr->is_ref = 1;
+ varptr->EA = 1;
/* at the end of this code refcount is always 1 */
}
varptr->refcount++;
@@ -1482,7 +1482,7 @@ send_by_ref:
if (zend_ptr_stack_get_arg(opline->op1.u.constant.value.lval, (void **) &param ELS_CC)==FAILURE) {
zend_error(E_NOTICE, "Missing argument %d for %s()\n", opline->op1.u.constant.value.lval, get_active_function_name());
DEC_AI_COUNT();
- } else if ((*param)->is_ref) {
+ } else if ((*param)->EA) {
zend_assign_to_variable_reference(NULL, get_zval_ptr_ptr(&opline->result, Ts, BP_VAR_W), param, NULL ELS_CC);
} else {
zend_assign_to_variable(NULL, &opline->result, NULL, *param, IS_VAR, Ts ELS_CC);
@@ -1509,7 +1509,7 @@ send_by_ref:
*default_value = tmp;
}
default_value->refcount=0;
- default_value->is_ref=0;
+ default_value->EA=0;
param = &default_value;
assignment_value = default_value;
} else {
@@ -1520,7 +1520,7 @@ send_by_ref:
assignment_value = *param;
}
- if (assignment_value->is_ref) {
+ if (assignment_value->EA) {
zend_assign_to_variable_reference(NULL, get_zval_ptr_ptr(&opline->result, Ts, BP_VAR_W), param, NULL ELS_CC);
} else {
zend_assign_to_variable(NULL, &opline->result, NULL, assignment_value, IS_VAR, Ts ELS_CC);
@@ -1622,16 +1622,16 @@ send_by_ref:
*new_expr = *expr;
expr = new_expr;
expr->refcount=1;
- expr->is_ref=0;
+ expr->EA=0;
} else {
- if (expr->is_ref) {
+ if (expr->EA) {
zval *new_expr = (zval *) emalloc(sizeof(zval));
*new_expr = *expr;
expr = new_expr;
zendi_zval_copy_ctor(*expr);
expr->refcount=1;
- expr->is_ref=0;
+ expr->EA=0;
} else {
expr->refcount++;
}
@@ -1810,7 +1810,7 @@ send_by_ref:
key = (zval *) emalloc(sizeof(zval));
key->refcount=1;
- key->is_ref=0;
+ key->EA=0;
switch (zend_hash_get_current_key(array->value.ht, &str_key, &int_key)) {
case HASH_KEY_IS_STRING:
key->value.str.val = str_key;