From 746c5869735679420c4da5200d372a6db630f64f Mon Sep 17 00:00:00 2001 From: Sergiu Ivanov Date: Thu, 27 Jan 2022 21:10:37 +0100 Subject: [PATCH] utils.rkt: Remove the left-over definitions of read-org-sexp and unorg. --- utils.rkt | 18 ------------------ 1 file changed, 18 deletions(-) diff --git a/utils.rkt b/utils.rkt index 6812da0..09bc324 100644 --- a/utils.rkt +++ b/utils.rkt @@ -304,24 +304,6 @@ ;;; A string variable mapping is a mapping from variables to strings. (define (string-variable-mapping? dict) (hash/c symbol? string?)) -;;; Reads a sexp from a string produced by Org-mode for a named table. -;;; See example.org for examples. -(define read-org-sexp - (compose ((curry map-sexp) (match-lambda - [(and (? string?) str) (string->any str)] - [x x])) - string->any)) - -;;; A shortcut for read-org-sexp. -(define unorg read-org-sexp) - -(module+ test - (test-case "read-org-sexp" - (check-equal? (read-org-sexp "((\"a\" \"(and a b)\") (\"b\" \"(or b (not a))\"))") - '((a (and a b)) (b (or b (not a))))) - (check-equal? (read-org-sexp "(#t \"#t\" \"#t \" '(1 2 \"#f\"))") - '(#t #t #t '(1 2 #f))))) - ;;; A contract allowing pairs constructed via cons or via list. (define (general-pair/c key-contract val-contract) (or/c (list/c key-contract val-contract)