mirror of
https://github.com/php/php-src.git
synced 2024-12-14 04:16:30 +08:00
Changing the regex for %f so the it will match E-, E+ and E.
This commit is contained in:
parent
b6963efdda
commit
7ba55c586a
@ -1557,7 +1557,7 @@ COMMAND $cmd
|
||||
$wanted_re = str_replace('%i', '[+-]?\d+', $wanted_re);
|
||||
$wanted_re = str_replace('%d', '\d+', $wanted_re);
|
||||
$wanted_re = str_replace('%x', '[0-9a-fA-F]+', $wanted_re);
|
||||
$wanted_re = str_replace('%f', '[+-]?\.?\d+\.?\d*(?:E-?\d+)?', $wanted_re);
|
||||
$wanted_re = str_replace('%f', '[+-]?\.?\d+\.?\d*(?:E[+-]?\d+)?', $wanted_re);
|
||||
$wanted_re = str_replace('%c', '.', $wanted_re);
|
||||
// %f allows two points "-.0.0" but that is the best *simple* expression
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user