summaryrefslogtreecommitdiff
path: root/ext/intl/collator/collator_is_numeric.c
diff options
context:
space:
mode:
authorGeorge Peter Banyard <girgias@php.net>2020-09-21 15:38:26 +0100
committerGeorge Peter Banyard <girgias@php.net>2020-09-21 16:29:10 +0100
commitddd99a700563af06e8897901abf87e5da73009e6 (patch)
tree53e81c6ecf5b6730a23d81357c8d0114b6946ae9 /ext/intl/collator/collator_is_numeric.c
parent2b6f5eec6c3d2b0596f7376ec41b316d1c4ac4e7 (diff)
downloadphp-git-ddd99a700563af06e8897901abf87e5da73009e6.tar.gz
Drop -1 mode for collator_is_numeric()
It is used only once with allow_errors enabled
Diffstat (limited to 'ext/intl/collator/collator_is_numeric.c')
-rw-r--r--ext/intl/collator/collator_is_numeric.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/ext/intl/collator/collator_is_numeric.c b/ext/intl/collator/collator_is_numeric.c
index 553b9d11ed..3fa9c0d13b 100644
--- a/ext/intl/collator/collator_is_numeric.c
+++ b/ext/intl/collator/collator_is_numeric.c
@@ -207,7 +207,7 @@ static zend_long collator_u_strtol(nptr, endptr, base)
/* {{{ collator_is_numeric]
* Taken from PHP6:is_numeric_unicode()
*/
-zend_uchar collator_is_numeric( UChar *str, int32_t length, zend_long *lval, double *dval, int allow_errors )
+zend_uchar collator_is_numeric( UChar *str, int32_t length, zend_long *lval, double *dval, bool allow_errors )
{
zend_long local_lval;
double local_dval;
@@ -252,9 +252,6 @@ zend_uchar collator_is_numeric( UChar *str, int32_t length, zend_long *lval, dou
if (!allow_errors) {
return 0;
}
- if (allow_errors == -1) {
- zend_error(E_NOTICE, "A non well formed numeric value encountered");
- }
if (allow_errors) {
if (end_ptr_double > end_ptr_long && dval) {