[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Arguing for a nilp function and where to put it
From: |
tomas |
Subject: |
Re: Arguing for a nilp function and where to put it |
Date: |
Sat, 1 Apr 2023 08:01:14 +0200 |
On Sat, Apr 01, 2023 at 07:37:44AM +0200, Pedro Andres Aranda Gutierrez wrote:
> Use case for a nilp function:
>
> I have a buffer-local variable with a default value, and I want to
> allow to (silently) set it to nil (and only to nil) from
> .dir-locals.el or Local Variables.
>
> Currently I have
>
> (defun nilp(v) (unless v t))
If I understand your needs correctly, the function you are
looking for is called `null'.
Yes, it breaks the convention for predicates (i.e. that they
should end in -p), but I think it's just because it has been
there for so long, like an old olive tree :-)
Cheers
--
t
signature.asc
Description: PGP signature
- Arguing for a nilp function and where to put it, Pedro Andres Aranda Gutierrez, 2023/04/01
- Re: Arguing for a nilp function and where to put it,
tomas <=
- Re: Arguing for a nilp function and where to put it, Michael Albinus, 2023/04/01
- Re: Arguing for a nilp function and where to put it, Eli Zaretskii, 2023/04/01
- Re: Arguing for a nilp function and where to put it, Pedro Andres Aranda Gutierrez, 2023/04/01
- Re: Arguing for a nilp function and where to put it, Roland Winkler, 2023/04/02
- Re: Arguing for a nilp function and where to put it, Richard Stallman, 2023/04/02
- Re: Arguing for a nilp function and where to put it, Emanuel Berg, 2023/04/03
- Re: Arguing for a nilp function and where to put it, Andreas Schwab, 2023/04/03
- Re: Arguing for a nilp function and where to put it, Roland Winkler, 2023/04/03
- Re: Arguing for a nilp function and where to put it, Emanuel Berg, 2023/04/03
- Re: Arguing for a nilp function and where to put it, Richard Stallman, 2023/04/03