summaryrefslogtreecommitdiff
path: root/json.lisp
diff options
context:
space:
mode:
authorJuan Manuel Tomás <jtomas1815@gmail.com>2022-10-31 06:58:00 -0300
committerJuan Manuel Tomás <jtomas1815@gmail.com>2022-10-31 06:58:00 -0300
commite04918e60ca56d0ab24eff72ef675a08c961e335 (patch)
treebf52c97de08771154d08ec8464c15f2dbfe120a2 /json.lisp
parentea1ef4c6ad6788bafe232f91d9a1bf03d48e4ff3 (diff)
downloadjson-e04918e60ca56d0ab24eff72ef675a08c961e335.tar.gz
json-e04918e60ca56d0ab24eff72ef675a08c961e335.zip
Adjust code to changes in monparser
Diffstat (limited to 'json.lisp')
-rw-r--r--json.lisp16
1 files changed, 8 insertions, 8 deletions
diff --git a/json.lisp b/json.lisp
index 2bc94db..cb94985 100644
--- a/json.lisp
+++ b/json.lisp
@@ -6,17 +6,17 @@
(char= x #\+))))))
(natural (one-or-more (unit #'digit-char-p))))
(cons sign natural))))
- (comp ((base (any signed-digits
- (fail "Malformed number.")))
+ (comp ((base (either signed-digits
+ (fail "Malformed number.")))
(dot (zero-or-one (unit (lambda (x) (char= x #\.)))))
(fraction (if dot
- (any (one-or-more (unit #'digit-char-p))
- (fail "Malformed fractional part."))
- (new nil)))
+ (either (one-or-more (unit #'digit-char-p))
+ (fail "Malformed fractional part."))
+ nothing))
(e (zero-or-one (unit (lambda (x) (or (char= x #\e)
(char= x #\E))))))
(exponent (if e
- (any signed-digits
- (fail "Malformed exponent part."))
- (new nil))))
+ (either signed-digits
+ (fail "Malformed exponent part."))
+ nothing)))
(list 'number base fraction exponent))))