From 5fe21fbeefe109f400aef40a51f71af111546fa3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ludovic=20Court=C3=A8s?= Date: Wed, 24 Apr 2013 14:44:33 +0200 Subject: [PATCH] utils: Fix column number returned by `source-properties->location'. * guix/utils.scm (source-properties->location): Use COL, not COL + 1. --- guix/utils.scm | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/guix/utils.scm b/guix/utils.scm index ad1c463be8c3fb60e41451028f63db523a5f5d8c..4f399b95c3b192dcb9af9df58785ea144d2d67d8 100644 --- a/guix/utils.scm +++ b/guix/utils.scm @@ -533,5 +533,6 @@ etc." (let ((file (assq-ref loc 'filename)) (line (assq-ref loc 'line)) (col (assq-ref loc 'column))) - ;; In accordance with the GCS, start line and column numbers at 1. - (location file (and line (+ line 1)) (and col (+ col 1))))) + ;; In accordance with the GCS, start line and column numbers at 1. Note + ;; that unlike LINE and `port-column', COL is actually 1-indexed here... + (location file (and line (+ line 1)) col)))