RE: [PHP-DEV] Adding "numeric" type hint
| From: | François Laupretre | Date: | Wed, 29 Apr 2015 10:03:54 +0000 |
| Subject: | RE: [PHP-DEV] Adding "numeric" type hint | ||
| References: | 1 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-86013@lists.php.net to get a copy of this message | ||
> De : yohgaki@gmail.com [mailto:yohgaki@gmail.com] De la part de Yasuo
> Ohgaki
>
> External data can have any form of numbers.
> Current PHP can handle them as "string". However PHP7's type hint cannot
> handle numeric data well because it only has "int" and "float" hints.
>
> http://3v4l.org/6J0bZ
I don't understand the error message. PHP 7 is supposed to accept numeric strings for
'int'. Is it too big for an int ? In this case, it is a conversion failure, the error
message is wrong and should be replaced. About 32/64 bit integers, this is another subject that was
partially hidden, as many others, by the STH war.
Regards
François