summaryrefslogtreecommitdiff
path: root/guix
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2017-06-21 11:58:39 +0200
committerLudovic Courtès <ludo@gnu.org>2017-06-21 11:59:33 +0200
commit2e2b5ad7bbf6cf693519e51500ad1cc7dce93ef5 (patch)
tree27e274e9001b2d9faef7d64e31619dfe1a8d9ed7 /guix
parent1804d21017ddc3626881105efaece5809b66dcb4 (diff)
profiles: Move 'manifest-entry-dependencies' user after definition.
Reported by Efraim Flashner. * guix/profiles.scm (manifest-transitive-entries): Move after <manifest-entry> definition.
Diffstat (limited to 'guix')
-rw-r--r--guix/profiles.scm34
1 files changed, 17 insertions, 17 deletions
diff --git a/guix/profiles.scm b/guix/profiles.scm
index 9858ec7b35..0c70975f7e 100644
--- a/guix/profiles.scm
+++ b/guix/profiles.scm
@@ -159,23 +159,6 @@
;; Convenient alias, to avoid name clashes.
(define make-manifest manifest)
-(define (manifest-transitive-entries manifest)
- "Return the entries of MANIFEST along with their propagated inputs,
-recursively."
- (let loop ((entries (manifest-entries manifest))
- (result '())
- (visited (set))) ;compare with 'equal?'
- (match entries
- (()
- (reverse result))
- ((head . tail)
- (if (set-contains? visited head)
- (loop tail result visited)
- (loop (append (manifest-entry-dependencies head)
- tail)
- (cons head result)
- (set-insert head visited)))))))
-
(define-record-type* <manifest-entry> manifest-entry
make-manifest-entry
manifest-entry?
@@ -200,6 +183,23 @@ recursively."
(output manifest-pattern-output ; string | #f
(default "out")))
+(define (manifest-transitive-entries manifest)
+ "Return the entries of MANIFEST along with their propagated inputs,
+recursively."
+ (let loop ((entries (manifest-entries manifest))
+ (result '())
+ (visited (set))) ;compare with 'equal?'
+ (match entries
+ (()
+ (reverse result))
+ ((head . tail)
+ (if (set-contains? visited head)
+ (loop tail result visited)
+ (loop (append (manifest-entry-dependencies head)
+ tail)
+ (cons head result)
+ (set-insert head visited)))))))
+
(define (profile-manifest profile)
"Return the PROFILE's manifest."
(let ((file (string-append profile "/manifest")))