From df7bbd381352d3241458488d028ba757e206674d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ludovic=20Court=C3=A8s?= Date: Sat, 6 Oct 2012 01:24:46 +0200 Subject: [PATCH] derivations: Set input port to UTF-8 in `read-derivation'. * guix/derivations.scm (read-derivation): Set DRV-PORT's encoding to UTF-8. --- guix/derivations.scm | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/guix/derivations.scm b/guix/derivations.scm index c9db580de6faa54c6e247e730ab95d4741d734a6..4ecf85aca205ea9b30d93ac4f4d144225d70a83a 100644 --- a/guix/derivations.scm +++ b/guix/derivations.scm @@ -171,6 +171,10 @@ available in STORE, recursively." '() x)) + ;; The contents of a derivation are typically ASCII, but choosing + ;; UTF-8 allows us to take the fast path for Guile's `scm_getc'. + (set-port-encoding! drv-port "UTF-8") + (let loop ((exp (read drv-port)) (result '())) (match exp