aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHugo Hörnquist <hugo@lysator.liu.se>2023-02-23 06:08:04 +0100
committerHugo Hörnquist <hugo@lysator.liu.se>2023-04-10 22:58:54 +0200
commit3df2a2908ccb8904c3f5d1f40588a2bfd78152b2 (patch)
tree256ca007180d7d152fcb38f713daaf711662e150
parentChange child/parent interface for vcomponent. (diff)
downloadcalp-3df2a2908ccb8904c3f5d1f40588a2bfd78152b2.tar.gz
calp-3df2a2908ccb8904c3f5d1f40588a2bfd78152b2.tar.xz
Fix guile3 deprecation notices.
-rw-r--r--module/hnh/module-introspection/module-uses.scm2
-rw-r--r--module/hnh/util.scm4
-rw-r--r--tests/test/add-and-save.scm6
3 files changed, 8 insertions, 4 deletions
diff --git a/module/hnh/module-introspection/module-uses.scm b/module/hnh/module-introspection/module-uses.scm
index b82aa6d0..3bed2a5e 100644
--- a/module/hnh/module-introspection/module-uses.scm
+++ b/module/hnh/module-introspection/module-uses.scm
@@ -82,6 +82,8 @@
(_ '())))
;; find all use-modules forms, and return what they pull in
+;; NOTE this will pull in all forms looking like a (use-modules ...)
+;; form, even if they are quoted, or in a cond-expand
(define (module-use-module-uses forms)
(match forms
(('use-modules modules ...)
diff --git a/module/hnh/util.scm b/module/hnh/util.scm
index ba2a8a59..759cdd48 100644
--- a/module/hnh/util.scm
+++ b/module/hnh/util.scm
@@ -70,6 +70,10 @@
:replace (set! define-syntax
when unless))
+(cond-expand
+ (guile-3 (use-modules ((ice-9 copy-tree) :select (copy-tree))))
+ (else))
+
((@ (guile) define-syntax) define-syntax
(syntax-rules ()
((_ (name args ...) body ...)
diff --git a/tests/test/add-and-save.scm b/tests/test/add-and-save.scm
index fb3277bb..efbfe09e 100644
--- a/tests/test/add-and-save.scm
+++ b/tests/test/add-and-save.scm
@@ -71,14 +71,12 @@
#2021-12-21T11:45:00)
))
-;; TODO tmpnam is deprecated
-(define directory (tmpnam))
+(define directory (mkdtemp (string-copy"/tmp/guile-test-XXXXXX")))
+(format #t "Using ~a~%" directory)
(define event-object ((@ (oop goops) make)
(@@ (vcomponent util instance methods) <events>)))
-(mkdir directory)
-(format #t "Using ~a~%" directory)
(define calendar
(vcalendar