Home
last modified time | relevance | path

Searched refs:key (Results 1 – 22 of 22) sorted by relevance

/ext-ds/src/php/objects/
H A Dphp_pair.c24 php_ds_pair_t *php_ds_pair_ex(zval *key, zval *value) in php_ds_pair_ex() argument
28 php_ds_pair_set_key(obj, key); in php_ds_pair_ex()
36 zval *key = php_ds_pair_get_key(obj); in php_ds_pair_create_clone() local
39 return (zend_object *) php_ds_pair_ex(key, val); in php_ds_pair_create_clone()
90 zval *key = php_ds_pair_get_key(obj); in php_ds_pair_to_array() local
95 add_assoc_zval(result, "key", key); in php_ds_pair_to_array()
98 Z_TRY_ADDREF_P(key); in php_ds_pair_to_array()
104 zval *key, *val; in php_ds_pair_serialize() local
112 key = php_ds_pair_get_key(pair); in php_ds_pair_serialize()
128 zval *key, *value; in php_ds_pair_unserialize() local
[all …]
H A Dphp_map.c34 zval *key; in ds_map_pairs_to_php_hashtable() local
42 DS_HTABLE_FOREACH_KEY_VALUE(map->table, key, value) { in ds_map_pairs_to_php_hashtable()
43 ZVAL_DS_PAIR(&pair, php_ds_pair_ex(key, value)); in ds_map_pairs_to_php_hashtable()
56 zval *key; in ds_map_pairs() local
59 DS_HTABLE_FOREACH_KEY_VALUE(map->table, key, value) { in ds_map_pairs()
60 ZVAL_DS_PAIR(target++, php_ds_pair_ex(key, value)); in ds_map_pairs()
H A Dphp_set.c42 zval *key; in php_ds_set_serialize() local
45 DS_HTABLE_FOREACH_KEY(set->table, key) { in php_ds_set_serialize()
46 php_var_serialize(&buf, key, &serialize_data); in php_ds_set_serialize()
H A Dphp_pair.h27 php_ds_pair_t *php_ds_pair_ex(zval *key, zval *value);
30 void php_ds_pair_set_key(php_ds_pair_t *obj, zval *key);
/ext-ds/src/ds/
H A Dds_htable.c176 return Z_TYPE_P(key) == IS_OBJECT && instanceof_function(Z_OBJCE_P(key), hashable_ce); in implements_hashable()
197 if (Z_TYPE_P(key) == IS_OBJECT && implements_hashable(key)) { in key_is_identical()
206 return key_is_identical(&bucket->key, key); in ds_htable_bucket_key_match()
341 zval *key, in ds_htable_lookup_bucket_by_hash() argument
369 return ds_htable_lookup_bucket_by_hash(table, key, get_hash(key)); in ds_htable_lookup_by_key()
658 zval *key, in ds_htable_init_next_bucket() argument
666 ZVAL_COPY(&bucket->key, key); in ds_htable_init_next_bucket()
785 zval *key; in ds_htable_join_keys() local
1032 zval *key, *value; in ds_htable_reduce() local
1170 zval *key; in ds_htable_to_array() local
[all …]
H A Dds_htable.h18 #define DS_HTABLE_BUCKET_HASH(_bucket) (Z_NEXT((_bucket)->key))
29 #define DS_HTABLE_BUCKET_DELETED(_bucket) (Z_ISUNDEF((_bucket)->key))
71 ZVAL_COPY(&_dst->key, &_src->key); \
82 DTOR_AND_UNDEF(&(b)->key); \
111 k = &_b->key; \
122 k = &_x->key;
140 k = &_x->key; \
148 zval key; member
179 bool ds_htable_has_key(ds_htable_t *table, zval *key);
183 void ds_htable_put(ds_htable_t *h, zval *key, zval *value);
[all …]
H A Dds_map.c50 void ds_map_put(ds_map_t *map, zval *key, zval *value) in ds_map_put() argument
52 ds_htable_put(map->table, key, value); in ds_map_put()
94 zval *value = ds_htable_get(map->table, key); in ds_map_get()
127 bool ds_map_has_key(ds_map_t *map, zval *key) in ds_map_has_key() argument
129 return ds_htable_has_key(map->table, key); in ds_map_has_key()
285 zval key; in iterator_add() local
289 ds_map_put((ds_map_t *) puser, &key, value); in iterator_add()
290 zval_ptr_dtor(&key); in iterator_add()
303 zend_string *key; in add_ht_to_map() local
308 if (key) { in add_ht_to_map()
[all …]
H A Dds_map.h24 zval *ds_map_get(ds_map_t *map, zval *key, zval *def);
25 void ds_map_put(ds_map_t *map, zval *key, zval *value);
26 void ds_map_remove(ds_map_t *map, zval *key, zval *def, zval *return_value);
28 bool ds_map_has_key(ds_map_t *map, zval *key);
H A Dds_set.c135 return &bucket->key; in ds_set_get()
151 return &bucket->key; in ds_set_get_first()
163 return &bucket->key; in ds_set_get_last()
/ext-ds/src/php/iterators/
H A Dphp_htable_iterator.c56 return &bucket->key; in php_ds_htable_iterator_get_current_keyval()
62 static void php_ds_htable_iterator_get_current_key(zend_object_iterator *iter, zval *key) in php_ds_htable_iterator_get_current_key() argument
68 ZVAL_COPY(key, &bucket->key); in php_ds_htable_iterator_get_current_key()
79 zval *key = &bucket->key; in php_ds_htable_iterator_get_current_pair() local
84 Z_TRY_ADDREF_P(key); in php_ds_htable_iterator_get_current_pair()
89 add_next_index_zval(arr, key); in php_ds_htable_iterator_get_current_pair()
98 static void php_ds_htable_iterator_get_current_pos(zend_object_iterator *iter, zval *key) in php_ds_htable_iterator_get_current_pos() argument
100 ZVAL_LONG(key, ((ds_htable_iterator_t *) iter)->position); in php_ds_htable_iterator_get_current_pos()
H A Dphp_deque_iterator.c31 static void php_ds_deque_iterator_get_current_key(zend_object_iterator *iter, zval *key) { in php_ds_deque_iterator_get_current_key() argument
32 ZVAL_LONG(key, ((php_ds_deque_iterator_t *) iter)->position); in php_ds_deque_iterator_get_current_key()
H A Dphp_vector_iterator.c28 static void php_ds_vector_iterator_get_current_key(zend_object_iterator *iter, zval *key) in php_ds_vector_iterator_get_current_key() argument
30 ZVAL_LONG(key, ((php_ds_vector_iterator_t *) iter)->position); in php_ds_vector_iterator_get_current_key()
H A Dphp_queue_iterator.c22 static void php_ds_queue_iterator_get_current_key(zend_object_iterator *iter, zval *key) { in php_ds_queue_iterator_get_current_key() argument
23 ZVAL_LONG(key, ((ds_queue_iterator_t *) iter)->position); in php_ds_queue_iterator_get_current_key()
H A Dphp_stack_iterator.c22 static void php_ds_stack_iterator_get_current_key(zend_object_iterator *iter, zval *key) { in php_ds_stack_iterator_get_current_key() argument
23 ZVAL_LONG(key, ((php_ds_stack_iterator_t *) iter)->position); in php_ds_stack_iterator_get_current_key()
H A Dphp_priority_queue_iterator.c25 static void php_ds_priority_queue_iterator_get_current_key(zend_object_iterator *iter, zval *key) { in php_ds_priority_queue_iterator_get_current_key() argument
26 ZVAL_LONG(key, ((php_ds_priority_queue_iterator *) iter)->position); in php_ds_priority_queue_iterator_get_current_key()
/ext-ds/src/php/classes/
H A Dphp_map_ce.h14 ARGINFO_ZVAL_ZVAL( Map_put, key, value);
16 ARGINFO_ZVAL_OPTIONAL_ZVAL( Map_get, key, default);
18 ARGINFO_ZVAL_OPTIONAL_ZVAL( Map_remove, key, default);
19 ARGINFO_ZVAL_RETURN_BOOL( Map_hasKey, key);
H A Dphp_pair_ce.c14 PARSE_OPTIONAL_ZVAL_OPTIONAL_ZVAL(key, value); in METHOD()
18 if (key) { in METHOD()
19 php_ds_pair_set_key(pair, key); in METHOD()
H A Dphp_map_ce.c50 PARSE_ZVAL_ZVAL(key, value); in METHOD()
51 ds_map_put(THIS_DS_MAP(), key, value); in METHOD()
62 PARSE_ZVAL_OPTIONAL_ZVAL(key, def); in METHOD()
63 RETURN_ZVAL_COPY(ds_map_get(THIS_DS_MAP(), key, def)); in METHOD()
74 PARSE_ZVAL_OPTIONAL_ZVAL(key, def); in METHOD()
75 ds_map_remove(THIS_DS_MAP(), key, def, return_value); in METHOD()
80 PARSE_ZVAL(key); in METHOD()
81 RETURN_BOOL(ds_map_has_key(THIS_DS_MAP(), key)); in METHOD()
H A Dphp_pair_ce.h10 ARGINFO_OPTIONAL_ZVAL_OPTIONAL_ZVAL( Pair___construct, key, value);
/ext-ds/src/
H A Dcommon.c222 zend_string *key; in ds_php_array_uses_keys() local
226 ZEND_HASH_FOREACH_KEY(ht, index, key) { in ds_php_array_uses_keys()
227 if (key || index != expected++) { in ds_php_array_uses_keys()
/ext-ds/.github/workflows/
H A Dmain.yml36 key: php-build-${{ matrix.php }}-zts-${{ matrix.zts }}
77 key: "composer-v2-cache-${{ matrix.php }}-${{ hashFiles('./composer.json') }}"
/ext-ds/
H A DCHANGELOG.md59 - Using a key as reference not working correctly with array access. #86

Completed in 44 milliseconds