summaryrefslogtreecommitdiff
path: root/README.org
diff options
context:
space:
mode:
Diffstat (limited to 'README.org')
-rw-r--r--README.org9
1 files changed, 3 insertions, 6 deletions
diff --git a/README.org b/README.org
index 1c18542..5e2b95e 100644
--- a/README.org
+++ b/README.org
@@ -133,16 +133,13 @@ Convert ~lst~ to a ~list?~ of ~json-value?~.
#+end_src
#+begin_src scheme
- (define-syntax case-values
- (syntax-rules ()
- ((_ vals (pattern body1 body2 ...) ...)
- (call-with-values (lambda () vals) (case-lambda (pattern body1 body2 ...) ...)))))
+ (import (srfi 210))
- (case-values (json-ref (json-object `("x" . ,(json-list "hello" "world"))) "x")
+ (case-receive (json-ref (json-object `("x" . ,(json-list "hello" "world"))) "x")
(() 'not-found)
((x) (json-list? x))) ; => #t
- (case-values (json-ref (json-object `("x" . ,(json-list "hello" "world"))) "y")
+ (case-receive (json-ref (json-object `("x" . ,(json-list "hello" "world"))) "y")
(() 'not-found)
((x) (json-list? x))) ; => not-found
#+end_src