@@ -276,10 +276,10 @@ typedef struct _zend_fcall_info_cache {
276
276
ZEND_API int zend_next_free_module (void );
277
277
278
278
BEGIN_EXTERN_C ()
279
- ZEND_API int _zend_get_parameters_array_ex (int param_count , zval * argument_array );
279
+ ZEND_API int _zend_get_parameters_array_ex (uint32_t param_count , zval * argument_array );
280
280
281
281
/* internal function to efficiently copy parameters when executing __call() */
282
- ZEND_API int zend_copy_parameters_array (int param_count , zval * argument_array );
282
+ ZEND_API int zend_copy_parameters_array (uint32_t param_count , zval * argument_array );
283
283
284
284
#define zend_get_parameters_array (ht , param_count , argument_array ) \
285
285
_zend_get_parameters_array_ex(param_count, argument_array)
@@ -462,7 +462,7 @@ static zend_always_inline int add_index_zval(zval *arg, zend_ulong index, zval *
462
462
463
463
ZEND_API int add_next_index_long (zval * arg , zend_long n );
464
464
ZEND_API int add_next_index_null (zval * arg );
465
- ZEND_API int add_next_index_bool (zval * arg , int b );
465
+ ZEND_API int add_next_index_bool (zval * arg , zend_bool b );
466
466
ZEND_API int add_next_index_resource (zval * arg , zend_resource * r );
467
467
ZEND_API int add_next_index_double (zval * arg , double d );
468
468
ZEND_API int add_next_index_str (zval * arg , zend_string * str );
@@ -523,11 +523,11 @@ ZEND_API void zend_fcall_info_args_clear(zend_fcall_info *fci, int free_mem);
523
523
/** Save current arguments from zend_fcall_info *fci
524
524
* params array will be set to NULL
525
525
*/
526
- ZEND_API void zend_fcall_info_args_save (zend_fcall_info * fci , int * param_count , zval * * params );
526
+ ZEND_API void zend_fcall_info_args_save (zend_fcall_info * fci , uint32_t * param_count , zval * * params );
527
527
528
528
/** Free arguments connected with zend_fcall_info *fci andset back saved ones.
529
529
*/
530
- ZEND_API void zend_fcall_info_args_restore (zend_fcall_info * fci , int param_count , zval * params );
530
+ ZEND_API void zend_fcall_info_args_restore (zend_fcall_info * fci , uint32_t param_count , zval * params );
531
531
532
532
/** Set or clear the arguments in the zend_call_info struct taking care of
533
533
* refcount. If args is NULL and arguments are set then those are cleared.
@@ -539,19 +539,19 @@ ZEND_API int zend_fcall_info_args_ex(zend_fcall_info *fci, zend_function *func,
539
539
* If argc is 0 the arguments which are set will be cleared, else pass
540
540
* a variable amount of zval** arguments.
541
541
*/
542
- ZEND_API int zend_fcall_info_argp (zend_fcall_info * fci , int argc , zval * argv );
542
+ ZEND_API void zend_fcall_info_argp (zend_fcall_info * fci , uint32_t argc , zval * argv );
543
543
544
544
/** Set arguments in the zend_fcall_info struct taking care of refcount.
545
545
* If argc is 0 the arguments which are set will be cleared, else pass
546
546
* a variable amount of zval** arguments.
547
547
*/
548
- ZEND_API int zend_fcall_info_argv (zend_fcall_info * fci , int argc , va_list * argv );
548
+ ZEND_API void zend_fcall_info_argv (zend_fcall_info * fci , uint32_t argc , va_list * argv );
549
549
550
550
/** Set arguments in the zend_fcall_info struct taking care of refcount.
551
551
* If argc is 0 the arguments which are set will be cleared, else pass
552
552
* a variable amount of zval** arguments.
553
553
*/
554
- ZEND_API int zend_fcall_info_argn (zend_fcall_info * fci , int argc , ...);
554
+ ZEND_API void zend_fcall_info_argn (zend_fcall_info * fci , uint32_t argc , ...);
555
555
556
556
/** Call a function using information created by zend_fcall_info_init()/args().
557
557
* If args is given then those replace the argument info in fci is temporarily.
@@ -591,7 +591,7 @@ static zend_always_inline void zend_call_known_instance_method_with_1_params(
591
591
ZEND_API void zend_call_known_instance_method_with_2_params (
592
592
zend_function * fn , zend_object * object , zval * retval_ptr , zval * param1 , zval * param2 );
593
593
594
- ZEND_API int zend_set_hash_symbol (zval * symbol , const char * name , int name_length , zend_bool is_ref , int num_symbol_tables , ...);
594
+ ZEND_API int zend_set_hash_symbol (zval * symbol , const char * name , size_t name_length , zend_bool is_ref , int num_symbol_tables , ...);
595
595
596
596
ZEND_API int zend_delete_global_variable (zend_string * name );
597
597
@@ -1230,14 +1230,14 @@ typedef enum _zend_expected_type {
1230
1230
} zend_expected_type ;
1231
1231
1232
1232
ZEND_API ZEND_COLD void ZEND_FASTCALL zend_wrong_parameters_none_error (void );
1233
- ZEND_API ZEND_COLD void ZEND_FASTCALL zend_wrong_parameters_count_error (int min_num_args , int max_num_args );
1234
- ZEND_API ZEND_COLD void ZEND_FASTCALL zend_wrong_parameter_error (int error_code , int num , char * name , zend_expected_type expected_type , zval * arg );
1235
- ZEND_API ZEND_COLD void ZEND_FASTCALL zend_wrong_parameter_type_error (int num , zend_expected_type expected_type , zval * arg );
1236
- ZEND_API ZEND_COLD void ZEND_FASTCALL zend_wrong_parameter_class_error (int num , const char * name , zval * arg );
1237
- ZEND_API ZEND_COLD void ZEND_FASTCALL zend_wrong_parameter_class_or_null_error (int num , const char * name , zval * arg );
1238
- ZEND_API ZEND_COLD void ZEND_FASTCALL zend_wrong_parameter_string_or_class_error (int num , const char * name , zval * arg );
1239
- ZEND_API ZEND_COLD void ZEND_FASTCALL zend_wrong_parameter_string_or_class_or_null_error (int num , const char * name , zval * arg );
1240
- ZEND_API ZEND_COLD void ZEND_FASTCALL zend_wrong_callback_error (int num , char * error );
1233
+ ZEND_API ZEND_COLD void ZEND_FASTCALL zend_wrong_parameters_count_error (uint32_t min_num_args , uint32_t max_num_args );
1234
+ ZEND_API ZEND_COLD void ZEND_FASTCALL zend_wrong_parameter_error (int error_code , uint32_t num , char * name , zend_expected_type expected_type , zval * arg );
1235
+ ZEND_API ZEND_COLD void ZEND_FASTCALL zend_wrong_parameter_type_error (uint32_t num , zend_expected_type expected_type , zval * arg );
1236
+ ZEND_API ZEND_COLD void ZEND_FASTCALL zend_wrong_parameter_class_error (uint32_t num , const char * name , zval * arg );
1237
+ ZEND_API ZEND_COLD void ZEND_FASTCALL zend_wrong_parameter_class_or_null_error (uint32_t num , const char * name , zval * arg );
1238
+ ZEND_API ZEND_COLD void ZEND_FASTCALL zend_wrong_parameter_string_or_class_error (uint32_t num , const char * name , zval * arg );
1239
+ ZEND_API ZEND_COLD void ZEND_FASTCALL zend_wrong_parameter_string_or_class_or_null_error (uint32_t num , const char * name , zval * arg );
1240
+ ZEND_API ZEND_COLD void ZEND_FASTCALL zend_wrong_callback_error (uint32_t num , char * error );
1241
1241
ZEND_API ZEND_COLD void ZEND_FASTCALL zend_argument_error (zend_class_entry * error_ce , uint32_t arg_num , const char * format , ...);
1242
1242
ZEND_API ZEND_COLD void ZEND_FASTCALL zend_argument_type_error (uint32_t arg_num , const char * format , ...);
1243
1243
ZEND_API ZEND_COLD void ZEND_FASTCALL zend_argument_value_error (uint32_t arg_num , const char * format , ...);
@@ -1254,10 +1254,10 @@ ZEND_API ZEND_COLD void ZEND_FASTCALL zend_argument_value_error(uint32_t arg_num
1254
1254
1255
1255
#define ZEND_PARSE_PARAMETERS_START_EX (flags , min_num_args , max_num_args ) do { \
1256
1256
const int _flags = (flags); \
1257
- int _min_num_args = (min_num_args); \
1258
- int _max_num_args = (max_num_args); \
1259
- int _num_args = EX_NUM_ARGS(); \
1260
- int _i = 0; \
1257
+ uint32_t _min_num_args = (min_num_args); \
1258
+ int _max_num_args = (max_num_args); /* TODO uint32_t */ \
1259
+ uint32_t _num_args = EX_NUM_ARGS (); \
1260
+ uint32_t _i = 0 ; \
1261
1261
zval * _real_arg , * _arg = NULL ; \
1262
1262
zend_expected_type _expected_type = Z_EXPECTED_LONG ; \
1263
1263
char * _error = NULL ; \
@@ -1683,7 +1683,7 @@ ZEND_API ZEND_COLD void ZEND_FASTCALL zend_argument_value_error(uint32_t arg_num
1683
1683
1684
1684
/* old "+" and "*" */
1685
1685
#define Z_PARAM_VARIADIC_EX (spec , dest , dest_num , post_varargs ) do { \
1686
- int _num_varargs = _num_args - _i - (post_varargs); \
1686
+ uint32_t _num_varargs = _num_args - _i - (post_varargs); \
1687
1687
if (EXPECTED(_num_varargs > 0)) { \
1688
1688
dest = _real_arg + 1; \
1689
1689
dest_num = _num_varargs; \
@@ -1730,7 +1730,7 @@ ZEND_API ZEND_COLD void ZEND_FASTCALL zend_argument_value_error(uint32_t arg_num
1730
1730
1731
1731
/* Inlined implementations shared by new and old parameter parsing APIs */
1732
1732
1733
- ZEND_API int ZEND_FASTCALL zend_parse_arg_class (zval * arg , zend_class_entry * * pce , int num , int check_null );
1733
+ ZEND_API int ZEND_FASTCALL zend_parse_arg_class (zval * arg , zend_class_entry * * pce , uint32_t num , int check_null );
1734
1734
ZEND_API int ZEND_FASTCALL zend_parse_arg_bool_slow (zval * arg , zend_bool * dest );
1735
1735
ZEND_API int ZEND_FASTCALL zend_parse_arg_bool_weak (zval * arg , zend_bool * dest );
1736
1736
ZEND_API int ZEND_FASTCALL zend_parse_arg_long_slow (zval * arg , zend_long * dest );
0 commit comments