summaryrefslogtreecommitdiff
path: root/Zend/zend_hash.h
diff options
context:
space:
mode:
authorBob Weinand <bobwei9@hotmail.com>2015-03-07 00:28:12 +0100
committerBob Weinand <bobwei9@hotmail.com>2015-03-07 00:28:12 +0100
commitb4a142ab974747be2fd03d055b30c63286a687fd (patch)
tree1d88392c6c1fe6c07d77d284f51c31d23bb78379 /Zend/zend_hash.h
parentfcdb6e0811953b2aa57f755632add0f67b01e6bc (diff)
downloadphp-git-b4a142ab974747be2fd03d055b30c63286a687fd.tar.gz
Added yield from operator
Diffstat (limited to 'Zend/zend_hash.h')
-rw-r--r--Zend/zend_hash.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/Zend/zend_hash.h b/Zend/zend_hash.h
index afa3602fae..6e349cd283 100644
--- a/Zend/zend_hash.h
+++ b/Zend/zend_hash.h
@@ -545,6 +545,15 @@ static zend_always_inline void *zend_hash_str_update_mem(HashTable *ht, const ch
return zend_hash_str_update_ptr(ht, str, len, p);
}
+static zend_always_inline void *zend_hash_index_add_ptr(HashTable *ht, zend_ulong h, void *pData)
+{
+ zval tmp, *zv;
+
+ ZVAL_PTR(&tmp, pData);
+ zv = zend_hash_index_add(ht, h, &tmp);
+ return zv ? Z_PTR_P(zv) : NULL;
+}
+
static zend_always_inline void *zend_hash_index_update_ptr(HashTable *ht, zend_ulong h, void *pData)
{
zval tmp, *zv;