note 91267 deleted from language.types.float by cmb
| From: | cmb@php.net | Date: | Mon, 11 Jul 2016 22:06:51 +0000 |
| Subject: | note 91267 deleted from language.types.float by cmb | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-205973@lists.php.net to get a copy of this message | ||
Note Submitter: rob at willo dot org
----
PHP will parse ".123" with no leading digit; just a decimal point. For a command-line
example:
php -r "echo 1 + .123;"
The regular expression provided above does not parse it.
My correction is:
EXPONENT_DNUM = "[+-]?({DNUM} | ({LNUM} | {DNUM}) [eE][+-]? {LNUM})"
NOTE: {LNUM} by itself is an integer, not a floating point.