aboutsummaryrefslogtreecommitdiff
path: root/module/sxml/transformations.scm
diff options
context:
space:
mode:
authorHugo Hörnquist <hugo@lysator.liu.se>2022-06-23 03:23:44 +0200
committerHugo Hörnquist <hugo@lysator.liu.se>2022-06-23 03:48:22 +0200
commit1976980d4a272fb7fc3694c734bfc6825edfc721 (patch)
tree8460db1176c64895e9968447588953fac85fe7d6 /module/sxml/transformations.scm
parentRemove all inline use-modules. (diff)
downloadcalp-1976980d4a272fb7fc3694c734bfc6825edfc721.tar.gz
calp-1976980d4a272fb7fc3694c734bfc6825edfc721.tar.xz
Centralize (almost) all exports to :export in define-module.
Diffstat (limited to 'module/sxml/transformations.scm')
-rw-r--r--module/sxml/transformations.scm11
1 files changed, 7 insertions, 4 deletions
diff --git a/module/sxml/transformations.scm b/module/sxml/transformations.scm
index 0978d71c..61de42aa 100644
--- a/module/sxml/transformations.scm
+++ b/module/sxml/transformations.scm
@@ -9,10 +9,13 @@
:use-module (hnh util)
:use-module ((srfi srfi-1) :select (concatenate))
:use-module ((sxml transform) :select (pre-post-order))
- )
+ :export (attribute-transformer
+ href-transformer
+ href-prefixer
+ ))
;; sxml, bindings → sxml
-(define-public (attribute-transformer
+(define (attribute-transformer
tree attribute-bindings)
(define bindings
@@ -24,13 +27,13 @@
(pre-post-order tree bindings))
-(define-public (href-transformer tree transformer)
+(define (href-transformer tree transformer)
(attribute-transformer
tree
`((href . ,(lambda (_ . content)
`(href ,@(transformer (string-concatenate (map ->str content))))
)))))
-(define-public (href-prefixer tree prefix)
+(define (href-prefixer tree prefix)
(href-transformer
tree (lambda (str) (string-append prefix str))))