5,337
edits
No edit summary |
No edit summary |
||
Line 16: | Line 16: | ||
Capturing significand and exponent separately. | Capturing significand and exponent separately. | ||
<syntaxhighlight lang="ragel"> | <syntaxhighlight lang="ragel"> | ||
([-+]?\d*\.?\d+)(?:[eE]([-+]?\d+)) | ([-+]?\d*\.?\d+)(?:[eE]([-+]?\d+))? | ||
</syntaxhighlight> | </syntaxhighlight> | ||
Capturing the entire string together. | Capturing the entire string together. | ||
<syntaxhighlight lang="ragel"> | <syntaxhighlight lang="ragel"> | ||
([-+]?\d*\.?\d+[eE][-+]?\d+) | ([-+]?\d*\.?\d+(?:[eE][-+]?\d+)?) | ||
</syntaxhighlight> | </syntaxhighlight> |