diff options
author | Dmitry Stogov <dmitry@zend.com> | 2016-11-28 22:59:57 +0300 |
---|---|---|
committer | Dmitry Stogov <dmitry@zend.com> | 2016-11-28 22:59:57 +0300 |
commit | 3e9bb03a62393d7bad1a0261b7a312c2ced8aac0 (patch) | |
tree | 9a35aa0f8ac2f155683ae8c87c985079c0f04806 /Zend/zend_builtin_functions.c | |
parent | 42407692b65e6752c43d7d1fbf4decd7ce3822ce (diff) | |
download | php-git-3e9bb03a62393d7bad1a0261b7a312c2ced8aac0.tar.gz |
Removed IS_TYPE_IMMUTABLE (it's the same as COPYABLE & !REFCOUED)
Diffstat (limited to 'Zend/zend_builtin_functions.c')
-rw-r--r-- | Zend/zend_builtin_functions.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/Zend/zend_builtin_functions.c b/Zend/zend_builtin_functions.c index 1faf57cf31..41da1f9537 100644 --- a/Zend/zend_builtin_functions.c +++ b/Zend/zend_builtin_functions.c @@ -836,7 +836,7 @@ static int validate_constant_array(HashTable *ht) /* {{{ */ ZVAL_DEREF(val); if (Z_REFCOUNTED_P(val)) { if (Z_TYPE_P(val) == IS_ARRAY) { - if (!Z_IMMUTABLE_P(val)) { + if (Z_REFCOUNTED_P(val)) { if (Z_ARRVAL_P(val)->u.v.nApplyCount > 0) { zend_error(E_WARNING, "Constants cannot be recursive arrays"); ret = 0; @@ -874,7 +874,7 @@ static void copy_constant_array(zval *dst, zval *src) /* {{{ */ new_val = zend_hash_index_add_new(Z_ARRVAL_P(dst), idx, val); } if (Z_TYPE_P(val) == IS_ARRAY) { - if (!Z_IMMUTABLE_P(val)) { + if (Z_REFCOUNTED_P(val)) { copy_constant_array(new_val, val); } } else if (Z_REFCOUNTED_P(val)) { @@ -932,7 +932,7 @@ repeat: val = &val_free; break; case IS_ARRAY: - if (!Z_IMMUTABLE_P(val)) { + if (Z_REFCOUNTED_P(val)) { if (!validate_constant_array(Z_ARRVAL_P(val))) { RETURN_FALSE; } else { |