[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#56799: (gnu services configuration) usage of *unspecified* is proble
From: |
Ludovic Courtès |
Subject: |
bug#56799: (gnu services configuration) usage of *unspecified* is problematic |
Date: |
Mon, 01 Aug 2022 15:49:32 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/28.1 (gnu/linux) |
Hi!
Maxim Cournoyer <maxim.cournoyer@gmail.com> skribis:
> Since commit 8cb1a49a3998c39f315a4199b7d4a121a6d66449, the
> define-configuration machinery in (gnu services configuration) uses
> *unspecified* instead of 'disabled for an unspecified field value.
As Attila wrote, the rationale as discussed in
<https://issues.guix.gnu.org/54674> was to specifically use a “special”
value without a read syntax in lieu of a symbol like 'disabled.
> While this is indeed an improvement in readability, it introduces an
> extra complication: because this new value is not self-quoting, it
> cannot be used as is in G-Exps, and values using it must be carefully
> expanded outside the gexp context, which is error prone.
Could you give a simple example of how this can happen?
In my experience, one would use ‘define-maybe’ and appropriate field
serializers such that *unspecified* never goes through. Previously
you’d check for (eq? x 'disabled) and now you just check for
(unspecified? x).
Thanks,
Ludo’.
- bug#56799: (gnu services configuration) usage of *unspecified* is problematic, Maxim Cournoyer, 2022/08/01
- bug#56799: (gnu services configuration) usage of *unspecified* is problematic, Ludovic Courtès, 2022/08/01
- bug#56799: (gnu services configuration) usage of *unspecified* is problematic,
Ludovic Courtès <=
- bug#56799: (gnu services configuration) usage of *unspecified* is problematic, Maxim Cournoyer, 2022/08/01
- bug#56799: (gnu services configuration) usage of *unspecified* is problematic, Ludovic Courtès, 2022/08/02
- bug#56799: (gnu services configuration) usage of *unspecified* is problematic, bokr, 2022/08/02
- bug#56799: (gnu services configuration) usage of *unspecified* is problematic, Maxim Cournoyer, 2022/08/02
- bug#56799: (gnu services configuration) usage of *unspecified* is problematic, Ludovic Courtès, 2022/08/04
- bug#56799: (gnu services configuration) usage of *unspecified* is problematic, Ludovic Courtès, 2022/08/07
- bug#56799: (gnu services configuration) usage of *unspecified* is problematic, Attila Lendvai, 2022/08/08
- bug#56799: (gnu services configuration) usage of *unspecified* is problematic, Attila Lendvai, 2022/08/08
- bug#56799: (gnu services configuration) usage of *unspecified* is problematic, Maxim Cournoyer, 2022/08/09
- bug#56799: (gnu services configuration) usage of *unspecified* is problematic, Maxim Cournoyer, 2022/08/09