po: Micro-optimize 'read-po-file'.

* guix/build/po.scm (parse-tree->assoc): Use dot instead of ellipsis in
'match' clause to avoid repeated calls to 'list?'.
This commit is contained in:
Ludovic Courtès 2020-06-22 23:33:20 +02:00
parent 52b4524f4e
commit 5837b3e41f
No known key found for this signature in database
GPG Key ID: 090B11993D9AEBB5
1 changed files with 2 additions and 2 deletions

View File

@ -55,8 +55,8 @@
(define (parse-tree->assoc parse-tree)
"Converts a po PARSE-TREE to an association list."
(match parse-tree
('() '())
((entry parse-tree ...)
(() '())
((entry . parse-tree)
(match entry
((? string? entry)
(parse-tree->assoc parse-tree))