From bf5e2c216c7e3b54f537e3a7e565d982baa547b5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kat=20March=C3=A1n?= Date: Tue, 31 Aug 2021 20:37:58 -0700 Subject: [PATCH] allow _ in post-decimal-point section Fixes: https://github.com/kdl-org/kdl/issues/69 --- SPEC.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/SPEC.md b/SPEC.md index ecea2d6..4d391ac 100644 --- a/SPEC.md +++ b/SPEC.md @@ -229,7 +229,7 @@ There are four syntaxes for Numbers: Decimal, Hexadecimal, Octal, and Binary. * Decimal numbers are a bit more special: * They have no radix prefix. * They use digits `0` through `9`, which may be separated by `_`. - * They may optionally include a decimal separator `.`, followed by more digits. + * They may optionally include a decimal separator `.`, followed by more digits, which may again be separated by `_`. * They may optionally be followed by `E` or `e`, an optional `-` or `+`, and more digits, to represent an exponent value. ### Boolean @@ -329,7 +329,7 @@ raw-string-quotes := '"' .* '"' number := decimal | hex | octal | binary -decimal := integer ('.' [0-9]+)? exponent? +decimal := integer ('.' [0-9] [0-9_]*)? exponent? exponent := ('e' | 'E') integer integer := sign? [0-9] [0-9_]* sign := '+' | '-'