diff options
author | Alex Sassmannshausen <alex@pompo.co> | 2016-11-12 17:12:53 +0100 |
---|---|---|
committer | Alex Sassmannshausen <alex@pompo.co> | 2016-11-14 00:06:09 +0100 |
commit | c91b368e96de9446bab37e7fab7d7c8ba71af946 (patch) | |
tree | 1bb5eca4db5100e2377b7f16ed10dec3caf7c621 | |
parent | d9721bcf27a049a87ee54701b8cb8e38dffd1a44 (diff) | |
download | guix-c91b368e96de9446bab37e7fab7d7c8ba71af946.tar.gz |
import/cpan: Maybe coerce version to string.
* guix/import/cpan.scm (cpan-module->sexp) <version>: Test if version in meta is string or number. If it is number, coerce to string.
-rw-r--r-- | guix/import/cpan.scm | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/guix/import/cpan.scm b/guix/import/cpan.scm index 5b7c47554a..d244969c9e 100644 --- a/guix/import/cpan.scm +++ b/guix/import/cpan.scm @@ -128,7 +128,9 @@ META." (string-append "perl-" (string-downcase name)))) (define version - (assoc-ref meta "version")) + (match (assoc-ref meta "version") + ((? number? vrs) (number->string vrs)) + ((? string? vrs) vrs))) (define core-module? (let ((perl-version (package-version perl)) |