me
/
guix
Archived
1
0
Fork 0

services: configuration: Add a define-configuration/no-serialization syntax.

This is added for convenience and for uniformity with the
define-maybe/no-serialization syntax introduced in the previous commit.

* gnu/services/configuration.scm
(define-configuration/no-serialization): New syntax.
master
Maxim Cournoyer 2021-05-17 10:18:34 -04:00
parent b7297d66c5
commit cdd1e15a25
No known key found for this signature in database
GPG Key ID: 1260E46482E63562
1 changed files with 8 additions and 0 deletions

View File

@ -44,6 +44,7 @@
configuration-error?
define-configuration
define-configuration/no-serialization
no-serialization
serialize-configuration
@ -222,6 +223,13 @@ does not have a default value" field kind)))
#t #'(_ stem (field (field-type def ...) doc custom-serializer ...)
...))))))
(define-syntax-rule (define-configuration/no-serialization
stem (field (field-type def ...)
doc custom-serializer ...) ...)
(define-configuration stem (field (field-type def ...)
doc custom-serializer ...) ...
(no-serialization)))
(define (empty-serializer field-name val) "")
(define serialize-package empty-serializer)