diff options
author | Eduardo Julian | 2019-03-13 21:14:22 -0400 |
---|---|---|
committer | Eduardo Julian | 2019-03-13 21:14:22 -0400 |
commit | 8e4b93bfc90ca81d615bf9dd5af43f29fdd0f5ae (patch) | |
tree | 0b343949908c11f8f27d70e4d40b1ccd0f969add /luxc/src | |
parent | 810c2c9f524603c161f265e4ed17c6556bdef959 (diff) |
Replaced the digit separator in numbers from "_" to ",".
Diffstat (limited to 'luxc/src')
-rw-r--r-- | luxc/src/lux/lexer.clj | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/luxc/src/lux/lexer.clj b/luxc/src/lux/lexer.clj index 8ed75b940..962e1e9bd 100644 --- a/luxc/src/lux/lexer.clj +++ b/luxc/src/lux/lexer.clj @@ -57,12 +57,12 @@ (do-template [<name> <tag> <regex>] (def <name> (|do [[meta _ token] (&reader/read-regex <regex>)] - (return (&/T [meta (<tag> (string/replace token #"_" ""))])))) + (return (&/T [meta (<tag> (string/replace token #"," ""))])))) - lex-nat $Nat #"^[0-9][0-9_]*" - lex-int $Int #"^(-|\+)[0-9][0-9_]*" - lex-rev $Rev #"^\.[0-9][0-9_]*" - lex-frac $Frac #"^(-|\+)[0-9][0-9_]*\.[0-9][0-9_]*((e|E)(-|\+)[0-9][0-9_]*)?" + lex-nat $Nat #"^[0-9][0-9,]*" + lex-int $Int #"^(-|\+)[0-9][0-9,]*" + lex-rev $Rev #"^\.[0-9][0-9,]*" + lex-frac $Frac #"^(-|\+)[0-9][0-9,]*\.[0-9][0-9,]*((e|E)(-|\+)[0-9][0-9,]*)?" ) (def +same-module-mark+ (str &/+name-separator+ &/+name-separator+)) |