[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Anti-ignore?
From: |
Pascal J. Bourguignon |
Subject: |
Re: Anti-ignore? |
Date: |
Fri, 11 Sep 2015 04:08:52 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux) |
Emanuel Berg <embe8573@student.uu.se> writes:
> "Pascal J. Bourguignon" <pjb@informatimago.com>
> writes:
>
>>> the `ignore' function accepts any number of
>>> arguments and returns nil. Is there a `canonical'
>>> function which would accept any number of arguments
>>> and return t? (Note: I /can/ implement it
>>> myself;-), I'm just curious whether this exists -
>>> I couldn't find it.)
>>
>> (funcall (constantly t) 'what 'ever) --> t
>
> That yields:
>
> (void-function constantly) in funcall
>
> How about:
Indeed, you are missing this function; it's in pjb-emacs.el
;; with lexical-binding:t of course:
(defun constantly (value)
(lambda (&rest arguments)
(declare (ignore arguments))
value))
--
__Pascal Bourguignon__ http://www.informatimago.com/
“The factory of the future will have only two employees, a man and a
dog. The man will be there to feed the dog. The dog will be there to
keep the man from touching the equipment.” -- Carl Bass CEO Autodesk