emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: thunk.el: Document that thunk-force == funcall?


From: Michael Heerdegen
Subject: Re: thunk.el: Document that thunk-force == funcall?
Date: Wed, 25 Nov 2020 15:16:40 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux)

Stefan Monnier <monnier@iro.umontreal.ca> writes:

>     (defalias 'thunk-function #'identity)

I like that idea.

> [ That's still pretty hypothetical.  ]
> I'd be curious to see concrete examples, to get a better idea of
> the tradeoffs.

I don't have any concrete real-life examples.  Only the one somewhat
unconventional that led me to this question:

I had been implementing my own improved version of `dired-mark-sexp'.
It offers some more boolean valued tests, and some are a bit more
expensive and partly interdepend, so I made them thunks.  When the input
expression is evaluated these are made accessible as functions.

I would rather do this via `thunk-let' and make these tests available as
contents of certain variables but then the repeated macroexpansion
slowed down the thing too much.


Regards,

Michael.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]