This commit is contained in:
Daniel Ziltener 2022-02-16 00:50:46 +01:00
parent c5370d839e
commit 23ad941e04
4 changed files with 16 additions and 16 deletions

View File

@ -153,12 +153,12 @@
(and (char? x) (and (char? x)
(fun x)))) (fun x))))
;;@(heading "Reading EDN") @(==== "Reading EDN")
(define tag-handlers (define tag-handlers
;;@("An a-list containing the handlers for reader tags. You can register your own reader tags by simply adding a new a-list entry. @("An a-list containing the handlers for reader tags. You can register your own reader tags by simply adding a new a-list entry.
;;
;;Example for a tag \"#keywordify\": add the entry `(cons keywordify: keywordify-procedure)`.") Example for a tag \"#keywordify\": add the entry `(cons keywordify: keywordify-procedure)`.")
(list (cons _: (lambda (input) edn/omit:)))) (list (cons _: (lambda (input) edn/omit:))))
(define reader-handlers (define reader-handlers
@ -204,7 +204,7 @@
(cdr result))))) (cdr result)))))
(define (read-edn port) (define (read-edn port)
;; @("Reads EDN data from given port, converts it to Chicken data and returns it. Precision suffixes for numbers get ignored, maps get converted to SRFI-69 hashtables, vectors to SRFI-4 vectors.") @("Reads EDN data from given port, converts it to Chicken data and returns it. Precision suffixes for numbers get ignored, maps get converted to SRFI-69 hashtables, vectors to SRFI-4 vectors.")
(second ((parse-edn '()) port))) (second ((parse-edn '()) port)))
;; EDN writing ;; EDN writing
@ -309,9 +309,9 @@
writer-handlers)) writer-handlers))
parse-entry in)) parse-entry in))
;;@(heading "Writing EDN") @(==== "Writing EDN")
(define (write-edn port struct) (define (write-edn port struct)
;; @("Converts Chicken data structures to EDN and writes it to the given port." @("Converts Chicken data structures to EDN and writes it to the given port."
;; (struct "A Chicken data structure consisting of atoms, lists, vectors and hashtables.")) (struct "A Chicken data structure consisting of atoms, lists, vectors and hashtables."))
(display (parse-entry struct) port)) (display (parse-entry struct) port))

View File

@ -5,9 +5,9 @@
(category parsing) (category parsing)
(license "BSD") (license "BSD")
(version "0.5.2") (version "0.5.2")
(dependencies r7rs srfi-69 srfi-1 hahn) (dependencies r7rs srfi-69 srfi-1 chalk)
(test-dependencies r7rs srfi-64 hahn) (test-dependencies r7rs srfi-64 chalk)
(components (extension edn (components (extension edn
(modules edn) (modules edn)
(csc-options "-X" "r7rs" "-R" "r7rs" "-X" "hahn") (csc-options "-X" "r7rs" "-R" "r7rs" "-X" "chalk")
))) )))

View File

@ -1,3 +1,4 @@
(repo git "https:///gitea.lyrion.ch/zilti/edn.git") (repo git "https:///gitea.lyrion.ch/zilti/edn.git")
(uri targz "https://gitea.lyrion.ch/zilti/edn/archive/{egg-release}.tar.gz") (uri targz "https://gitea.lyrion.ch/zilti/edn/archive/{egg-release}.tar.gz")
(release "0.5.2") (release "0.5.3") ;; Replaced Hahn with Chalk
(release "0.5.2") ;; Update for Chicken 5

View File

@ -1,9 +1,8 @@
@(heading "EDN") @(== "EDN")
@(text "This egg provides a parser and a writer for the [[https://github.com/edn-format/edn|Extensible Data Notation]].") @("This egg provides a parser and a writer for the [[https://github.com/edn-format/edn|Extensible Data Notation]].")
@(heading "Documentation") @(==="Documentation")
@(noop)
(import r7rs) (import r7rs)
(define-library (edn) (define-library (edn)