diff options
author | Eduardo Julian | 2018-07-14 02:59:41 -0400 |
---|---|---|
committer | Eduardo Julian | 2018-07-14 02:59:41 -0400 |
commit | 0c0472862f5c1e543e6c5614a4cd112ac7d4cc13 (patch) | |
tree | a94c7cd4bf3c916296c5341c5fc043ca71acb184 /luxc/src | |
parent | 69fefab57c40f323d759dc444dbcebad15071585 (diff) |
- New syntax for bit values: "#0" and "#1", instead of "false" and "true".
- Small improvements to lux-mode.
Diffstat (limited to 'luxc/src')
-rw-r--r-- | luxc/src/lux/lexer.clj | 2 | ||||
-rw-r--r-- | luxc/src/lux/parser.clj | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/luxc/src/lux/lexer.clj b/luxc/src/lux/lexer.clj index be8f8b69a..aac212e26 100644 --- a/luxc/src/lux/lexer.clj +++ b/luxc/src/lux/lexer.clj @@ -130,7 +130,7 @@ (|do [[meta _ token] (&reader/read-regex <regex>)] (return (&/T [meta (<tag> token)])))) - lex-bit $Bit #"^(true|false)" + lex-bit $Bit #"^(#0|#1)" ) (do-template [<name> <tag> <regex>] diff --git a/luxc/src/lux/parser.clj b/luxc/src/lux/parser.clj index 92a23da81..7a58059b0 100644 --- a/luxc/src/lux/parser.clj +++ b/luxc/src/lux/parser.clj @@ -65,7 +65,7 @@ (return &/$Nil) (&lexer/$Bit ?value) - (return (&/|list (&/T [meta (&/$Bit (Boolean/parseBoolean ?value))]))) + (return (&/|list (&/T [meta (&/$Bit (.equals ^String ?value "#1"))]))) (&lexer/$Nat ?value) (return (&/|list (&/T [meta (&/$Nat (Long/parseUnsignedLong ?value))]))) |