From: Lucien Cartier-Tilet <lucien@phundrak.com>
To: Stefan Monnier <monnier@iro.umontreal.ca>
Cc: emacs-devel@gnu.org
Subject: Re: [PATCH] Add new csetq macro
Date: Sun, 04 Sep 2022 13:40:41 +0200 [thread overview]
Message-ID: <87r10rz7kg.fsf@phundrak.com> (raw)
In-Reply-To: <jwvmtbg1oop.fsf-monnier+emacs@gnu.org>
[-- Attachment #1.1.1: Type: text/plain, Size: 891 bytes --]
> `custom-set-variables` seems to solve this problem of
> repetition already.
`custom-set-variables` explicitely does not evaluate the expressions
passed as arguments, while `csetq' does, like `setq' itself. Moreover, I
wanted to write this macro with the aim of being as close as possible
to `setq'’s syntax.
> But more importantly, I think your `csetq` has been recently added
> under the name `setopt`.
I did not know this macro existed, it seems to be indeed close to what
I intended. My only issue with it is you still have to quote the
custom variable you want to set, unlike `setq'.
,----
| (setopt 'custom-var1 value1
| 'custom-var2 value2)
| ;; vs
| (csetq custom-var1 value1
| custom-var2 value2)
`----
--
Lucien “Phundrak” Cartier-Tilet
<https://phundrak.com> (Français)
<https://phundrak.com/en> (English)
Sent from GNU/Emacs
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 861 bytes --]
next prev parent reply other threads:[~2022-09-04 11:40 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-09-03 14:07 [PATCH] Add new csetq macro Lucien Cartier-Tilet
2022-09-03 15:11 ` Stefan Monnier
2022-09-04 11:40 ` Lucien Cartier-Tilet [this message]
2022-09-04 11:53 ` Lars Ingebrigtsen
2022-09-04 11:55 ` Lucien Cartier-Tilet
2022-09-05 16:35 ` [External] : " Drew Adams
2022-09-03 15:16 ` Stefan Kangas
2022-09-04 11:46 ` Lucien Cartier-Tilet
2022-09-03 15:59 ` Philip Kaludercic
2022-09-04 11:48 ` Lucien Cartier-Tilet
2022-09-04 17:07 ` Philip Kaludercic
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87r10rz7kg.fsf@phundrak.com \
--to=lucien@phundrak.com \
--cc=emacs-devel@gnu.org \
--cc=monnier@iro.umontreal.ca \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).