[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
06/07: gexp: Remove special meaning of forms (PACKAGE OUTPUT) in ungexp.
From: |
Ludovic Courtès |
Subject: |
06/07: gexp: Remove special meaning of forms (PACKAGE OUTPUT) in ungexp. |
Date: |
Mon, 16 Mar 2015 22:27:53 +0000 |
civodul pushed a commit to branch wip-extensible-gexps
in repository guix.
commit 976ce9bd288863787d500682d0321cdb51dd77e7
Author: Ludovic Courtès <address@hidden>
Date: Sun Mar 15 21:59:19 2015 +0100
gexp: Remove special meaning of forms (PACKAGE OUTPUT) in ungexp.
* guix/gexp.scm (gexp-inputs)[add-reference-inputs]: Remove clause for
inputs of the form (PACKAGE OUTPUT).
(gexp->sexp)[reference->sexp]: Likewise.
* tests/gexp.scm ("input list splicing"): Change 'list' to 'gexp-input'
for glibc:debug.
("text-file*"): Likewise for %bootstrap-guile:out.
("input list splicing + gexp-input + ungexp-native-splicing"): Remove,
now redundant.
---
guix/gexp.scm | 11 -----------
tests/gexp.scm | 14 ++------------
2 files changed, 2 insertions(+), 23 deletions(-)
diff --git a/guix/gexp.scm b/guix/gexp.scm
index 76ce267..353c463 100644
--- a/guix/gexp.scm
+++ b/guix/gexp.scm
@@ -312,10 +312,6 @@ references."
(if (direct-store-path? str)
(cons `(,str) result)
result))
- (($ <gexp-input> ((? package? p) (? string? output)) _ native?)
- ;; XXX: For now, for backward-compatibility, automatically convert a
- ;; pair like this to an gexp-input for OUTPUT of P.
- (add-reference-inputs (gexp-input p output native?) result))
(($ <gexp-input> (lst ...) output native?)
(fold-right add-reference-inputs result
;; XXX: For now, automatically convert LST to a list of
@@ -373,13 +369,6 @@ and in the current monad setting (system type, etc.)"
#:output output
#:system system
#:target (if (or n? native?) #f target)))
- (($ <gexp-input> ((? package? p) (? string? output)) _ n?)
- ;; XXX: For backward compatibility, automatically interpret such a
- ;; pair.
- (package-file p
- #:output output
- #:system system
- #:target (if (or n? native?) #f target)))
(($ <gexp-input> (? origin? o) output)
(mlet %store-monad ((drv (origin->derivation o)))
(return (derivation->output-path drv output))))
diff --git a/tests/gexp.scm b/tests/gexp.scm
index 1e27407..4c31e22 100644
--- a/tests/gexp.scm
+++ b/tests/gexp.scm
@@ -196,7 +196,7 @@
(gexp->sexp* exp target)))))
(test-assert "input list splicing"
- (let* ((inputs (list (list glibc "debug") %bootstrap-guile))
+ (let* ((inputs (list (gexp-input glibc "debug") %bootstrap-guile))
(outputs (list (derivation->output-path
(package-derivation %store glibc)
"debug")
@@ -210,16 +210,6 @@
`(list ,@(cons 5 outputs))))))
(test-assert "input list splicing + ungexp-native-splicing"
- (let* ((inputs (list (list glibc "debug") %bootstrap-guile))
- (exp (gexp (list (ungexp-native-splicing (cons (+ 2 3) inputs))))))
- (and (lset= equal?
- `((,glibc "debug") (,%bootstrap-guile "out"))
- (gexp-native-inputs exp))
- (null? (gexp-inputs exp))
- (equal? (gexp->sexp* exp) ;native
- (gexp->sexp* exp "mips64el-linux")))))
-
-(test-assert "input list splicing + gexp-input + ungexp-native-splicing"
(let* ((inputs (list (gexp-input glibc "debug") %bootstrap-guile))
(exp (gexp (list (ungexp-native-splicing (cons (+ 2 3) inputs))))))
(and (lset= equal?
@@ -553,7 +543,7 @@
(file (text-file "bar" "This is bar."))
(text (text-file* "foo"
%bootstrap-guile "/bin/guile "
- `(,%bootstrap-guile "out") "/bin/guile "
+ (gexp-input %bootstrap-guile "out") "/bin/guile "
drv "/bin/guile "
file))
(done (built-derivations (list text)))
- branch wip-extensible-gexps created (now 20a3daa), Ludovic Courtès, 2015/03/16
- 01/07: tests: Add an indirection for white-box testing., Ludovic Courtès, 2015/03/16
- 02/07: gexp: Rename <output-ref> to <gexp-output>., Ludovic Courtès, 2015/03/16
- 03/07: gexp: Add <gexp-input>., Ludovic Courtès, 2015/03/16
- 04/07: gexp: Export 'gexp-input' constructor., Ludovic Courtès, 2015/03/16
- 05/07: profiles: Use 'gexp-input' instead of two-element lists., Ludovic Courtès, 2015/03/16
- 06/07: gexp: Remove special meaning of forms (PACKAGE OUTPUT) in ungexp.,
Ludovic Courtès <=
- 07/07: gexp: Separate "compilers" for origins and packages from the core., Ludovic Courtès, 2015/03/16