@@ -2046,7 +2046,7 @@ ZEND_METHOD(ReflectionFunctionAbstract, getParameters)
2046
2046
i < fptr -> common .required_num_args ,
2047
2047
& parameter
2048
2048
);
2049
- add_next_index_zval ( return_value , & parameter );
2049
+ zend_hash_next_index_insert_new ( Z_ARRVAL_P ( return_value ) , & parameter );
2050
2050
2051
2051
arg_info ++ ;
2052
2052
}
@@ -4239,7 +4239,7 @@ ZEND_METHOD(ReflectionClass, getMethod)
4239
4239
/* }}} */
4240
4240
4241
4241
/* {{{ _addmethod */
4242
- static void _addmethod (zend_function * mptr , zend_class_entry * ce , zval * retval , zend_long filter )
4242
+ static void _addmethod (zend_function * mptr , zend_class_entry * ce , HashTable * ht , zend_long filter )
4243
4243
{
4244
4244
if ((mptr -> common .fn_flags & ZEND_ACC_PRIVATE ) && mptr -> common .scope != ce ) {
4245
4245
return ;
@@ -4248,7 +4248,7 @@ static void _addmethod(zend_function *mptr, zend_class_entry *ce, zval *retval,
4248
4248
if (mptr -> common .fn_flags & filter ) {
4249
4249
zval method ;
4250
4250
reflection_method_factory (ce , mptr , NULL , & method );
4251
- add_next_index_zval ( retval , & method );
4251
+ zend_hash_next_index_insert_new ( ht , & method );
4252
4252
}
4253
4253
}
4254
4254
/* }}} */
@@ -4274,7 +4274,7 @@ ZEND_METHOD(ReflectionClass, getMethods)
4274
4274
4275
4275
array_init (return_value );
4276
4276
ZEND_HASH_FOREACH_PTR (& ce -> function_table , mptr ) {
4277
- _addmethod (mptr , ce , return_value , filter );
4277
+ _addmethod (mptr , ce , Z_ARRVAL_P ( return_value ) , filter );
4278
4278
} ZEND_HASH_FOREACH_END ();
4279
4279
4280
4280
if (instanceof_function (ce , zend_ce_closure )) {
@@ -4289,7 +4289,7 @@ ZEND_METHOD(ReflectionClass, getMethods)
4289
4289
}
4290
4290
zend_function * closure = zend_get_closure_invoke_method (obj );
4291
4291
if (closure ) {
4292
- _addmethod (closure , ce , return_value , filter );
4292
+ _addmethod (closure , ce , Z_ARRVAL_P ( return_value ) , filter );
4293
4293
}
4294
4294
if (!has_obj ) {
4295
4295
zval_ptr_dtor (& obj_tmp );
@@ -4392,7 +4392,7 @@ ZEND_METHOD(ReflectionClass, getProperty)
4392
4392
/* }}} */
4393
4393
4394
4394
/* {{{ _addproperty */
4395
- static void _addproperty (zend_property_info * pptr , zend_string * key , zend_class_entry * ce , zval * retval , long filter )
4395
+ static void _addproperty (zend_property_info * pptr , zend_string * key , zend_class_entry * ce , HashTable * ht , long filter )
4396
4396
{
4397
4397
if ((pptr -> flags & ZEND_ACC_PRIVATE ) && pptr -> ce != ce ) {
4398
4398
return ;
@@ -4401,7 +4401,7 @@ static void _addproperty(zend_property_info *pptr, zend_string *key, zend_class_
4401
4401
if (pptr -> flags & filter ) {
4402
4402
zval property ;
4403
4403
reflection_property_factory (ce , key , pptr , & property );
4404
- add_next_index_zval ( retval , & property );
4404
+ zend_hash_next_index_insert_new ( ht , & property );
4405
4405
}
4406
4406
}
4407
4407
/* }}} */
@@ -4450,7 +4450,7 @@ ZEND_METHOD(ReflectionClass, getProperties)
4450
4450
4451
4451
array_init (return_value );
4452
4452
ZEND_HASH_FOREACH_STR_KEY_PTR (& ce -> properties_info , key , prop_info ) {
4453
- _addproperty (prop_info , key , ce , return_value , filter );
4453
+ _addproperty (prop_info , key , ce , Z_ARRVAL_P ( return_value ) , filter );
4454
4454
} ZEND_HASH_FOREACH_END ();
4455
4455
4456
4456
if (Z_TYPE (intern -> obj ) != IS_UNDEF && (filter & ZEND_ACC_PUBLIC ) != 0 ) {
@@ -4543,7 +4543,7 @@ ZEND_METHOD(ReflectionClass, getReflectionConstants)
4543
4543
if (Z_ACCESS_FLAGS (constant -> value ) & filter ) {
4544
4544
zval class_const ;
4545
4545
reflection_class_constant_factory (name , constant , & class_const );
4546
- zend_hash_next_index_insert (Z_ARRVAL_P (return_value ), & class_const );
4546
+ zend_hash_next_index_insert_new (Z_ARRVAL_P (return_value ), & class_const );
4547
4547
}
4548
4548
} ZEND_HASH_FOREACH_END ();
4549
4549
}
@@ -6626,7 +6626,7 @@ ZEND_METHOD(ReflectionEnum, getCases)
6626
6626
if (Z_ACCESS_FLAGS (constant -> value ) & ZEND_CLASS_CONST_IS_CASE ) {
6627
6627
zval class_const ;
6628
6628
reflection_enum_case_factory (ce , name , constant , & class_const );
6629
- zend_hash_next_index_insert (Z_ARRVAL_P (return_value ), & class_const );
6629
+ zend_hash_next_index_insert_new (Z_ARRVAL_P (return_value ), & class_const );
6630
6630
}
6631
6631
} ZEND_HASH_FOREACH_END ();
6632
6632
}
0 commit comments