emacs-devel
[Top][All Lists]
Advanced

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

Re: defmacro with built-in gensym declaration and initialization


From: Basil L. Contovounesios
Subject: Re: defmacro with built-in gensym declaration and initialization
Date: Wed, 20 Jan 2021 13:46:16 +0000
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux)

akater <nuclearspace@gmail.com> writes:

> I suggest extending ~defmacro~ to support ~&gensym~ keyword in its
> lambda list, for convenient declaration and initialization of gensyms.

[...]

> This ~&gensym~ facility eliminates the need for ~with-gensyms~ and
> ~once-only~ in cases when gensyms are created unconditionally by macro
> function (in Common Lisp parlance).

IMO, this minor convenience is insufficient motivation for
conflating/complicating a macro's global arglist, i.e. its arity,
calling convention, etc., with utilities for its local body.  Is there
some other motivation?  Am I missing something?

Why not provide handy gensym/once-only local conveniences for macro
authors instead (some of which already exist in one form or another,
e.g. macroexp-let2, inline-letevals, and org-with-gensyms)?

Thanks,

-- 
Basil



reply via email to

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