diff options
author | Hugo Hörnquist <hugo@hornquist.se> | 2019-05-07 11:46:10 +0200 |
---|---|---|
committer | Hugo Hörnquist <hugo@hornquist.se> | 2019-05-13 09:08:39 +0200 |
commit | eeebc51438adec0f9b572420908184471f7eaa96 (patch) | |
tree | a362d9100abfe501acb38195df27657521790312 /module/util | |
parent | Improve glob. (diff) | |
download | calp-eeebc51438adec0f9b572420908184471f7eaa96.tar.gz calp-eeebc51438adec0f9b572420908184471f7eaa96.tar.xz |
Add preliminary use-modules* form.
Diffstat (limited to '')
-rw-r--r-- | module/util.scm | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/module/util.scm b/module/util.scm index dd5f3057..c41b8061 100644 --- a/module/util.scm +++ b/module/util.scm @@ -9,6 +9,7 @@ catch-multiple quote? re-export-modules + use-modules* tree-map let-lazy) #:replace (let* set! define-syntax when unless if)) @@ -333,3 +334,11 @@ (assq-set! alist k (append v (or o '()))))) (copy-tree a) b)) + +(define-macro (use-modules* . forms) + `(use-modules + ,@(concatenate + (map (lambda (form) + (map (lambda (sub) (list (car form) sub)) + (cadr form))) + forms)))) |