summaryrefslogtreecommitdiff
path: root/guix
diff options
context:
space:
mode:
Diffstat (limited to 'guix')
-rw-r--r--guix/records.scm3
1 files changed, 2 insertions, 1 deletions
diff --git a/guix/records.scm b/guix/records.scm
index 2a88cb4b3c..6c9f29eb3e 100644
--- a/guix/records.scm
+++ b/guix/records.scm
@@ -599,7 +599,8 @@ to thunked values. Raise a syntax violation when the field is not found."
((_ record field offset ())
(syntax-violation 'match-record
"unknown record type field"
- s #'field))
+ ;; Attach the local source data to the field.
+ (datum->syntax #f (syntax->datum #'field) #:source s)))
((_ record field offset ((head normal) tail ...))
(free-identifier=? #'field #'head)
#'(values offset identity))