com php-src: Removed IS_TYPE_COPYABLE flag from IS_ STRING zvals.: UPGRADING.INTERNALS Zend/zend_type s.h

From: Date: Thu, 18 Jan 2018 09:41:27 +0000
Subject: com php-src: Removed IS_TYPE_COPYABLE flag from IS_ STRING zvals.: UPGRADING.INTERNALS Zend/zend_type s.h
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-100959@lists.php.net to get a copy of this message
Commit: 1ee94f56c45c90a225900ccb99ff70080c583d5a Author: Dmitry Stogov <dmitry@zend.com> Thu, 18 Jan 2018 12:41:27 +0300 Parents: 0a336f942194fc6d37cc03c3e76e62b556f2fa67 Branches: master Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=1ee94f56c45c90a225900ccb99ff70080c583d5a Log: Removed IS_TYPE_COPYABLE flag from IS_STRING zvals. Changed paths: M UPGRADING.INTERNALS M Zend/zend_types.h Diff: diff --git a/UPGRADING.INTERNALS b/UPGRADING.INTERNALS index 45143ea..19eeacc 100644 --- a/UPGRADING.INTERNALS +++ b/UPGRADING.INTERNALS @@ -14,6 +14,7 @@ PHP 7.3 INTERNALS UPGRADE NOTES k. zend_fcall_info_cache.initialized l. php_hrtime_current() m. zend_cpu_supports() + n. IS_TYPE_COPYABLE 2. Build system changes a. Unix build system changes @@ -102,6 +103,11 @@ PHP 7.3 INTERNALS UPGRADE NOTES m. zend_cpu_supports() determines if a feature is supported by current cpu. + n. IS_STRING zvals don't set IS_TYPE_COPYALE anymore. This prevents string + duplication by zval_copy_ctor(), ZVAL_DUP() and SEPARATE_ZVAL*() macros. + Interned strings didn't set IS_TYPE_COPYALE, so they aren't affected at + all. + ======================== 2. Build system changes ======================== diff --git a/Zend/zend_types.h b/Zend/zend_types.h index 94650c5..24f2091 100644 --- a/Zend/zend_types.h +++ b/Zend/zend_types.h @@ -476,7 +476,7 @@ static zend_always_inline zend_uchar zval_get_type(const zval* pz) { /* extended types */ #define IS_INTERNED_STRING_EX IS_STRING -#define IS_STRING_EX (IS_STRING | ((IS_TYPE_REFCOUNTED | IS_TYPE_COPYABLE) << Z_TYPE_FLAGS_SHIFT)) +#define IS_STRING_EX (IS_STRING | ((IS_TYPE_REFCOUNTED ) << Z_TYPE_FLAGS_SHIFT)) #define IS_ARRAY_EX (IS_ARRAY | ((IS_TYPE_REFCOUNTED | IS_TYPE_COPYABLE) << Z_TYPE_FLAGS_SHIFT)) #define IS_OBJECT_EX (IS_OBJECT | ((IS_TYPE_REFCOUNTED ) << Z_TYPE_FLAGS_SHIFT)) #define IS_RESOURCE_EX (IS_RESOURCE | ((IS_TYPE_REFCOUNTED ) << Z_TYPE_FLAGS_SHIFT))

« previous php.cvs (#100959) next »