File tree Expand file tree Collapse file tree 1 file changed +9
-9
lines changed
Expand file tree Collapse file tree 1 file changed +9
-9
lines changed Original file line number Diff line number Diff line change @@ -148,6 +148,15 @@ PHP_MINFO_FUNCTION(bcmath)
148148}
149149/* }}} */
150150
151+ static zend_always_inline zend_result bcmath_check_scale (zend_long scale , uint32_t arg_num )
152+ {
153+ if (UNEXPECTED (scale < 0 || scale > INT_MAX )) {
154+ zend_argument_value_error (arg_num , "must be between 0 and %d" , INT_MAX );
155+ return FAILURE ;
156+ }
157+ return SUCCESS ;
158+ }
159+
151160static void php_long2num (bc_num * num , zend_long lval )
152161{
153162 * num = bc_long2num (lval );
@@ -1305,15 +1314,6 @@ static zend_always_inline zend_result bc_num_from_obj_or_str_or_long_with_err(
13051314 return SUCCESS ;
13061315}
13071316
1308- static zend_always_inline zend_result bcmath_check_scale (zend_long scale , uint32_t arg_num )
1309- {
1310- if (UNEXPECTED (scale < 0 || scale > INT_MAX )) {
1311- zend_argument_value_error (arg_num , "must be between 0 and %d" , INT_MAX );
1312- return FAILURE ;
1313- }
1314- return SUCCESS ;
1315- }
1316-
13171317PHP_METHOD (BcMath_Number , __construct )
13181318{
13191319 zend_string * str = NULL ;
You can’t perform that action at this time.
0 commit comments