From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Lucien Cartier-Tilet Newsgroups: gmane.emacs.devel Subject: Re: [PATCH] Add new csetq macro Date: Sun, 04 Sep 2022 13:40:41 +0200 Message-ID: <87r10rz7kg.fsf@phundrak.com> References: <20220903140723.809684-1-lucien@phundrak.com> Mime-Version: 1.0 Content-Type: multipart/signed; boundary="===-=-="; micalg=pgp-sha256; protocol="application/pgp-signature" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="9141"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: mu4e 1.8.8; emacs 29.0.50 Cc: emacs-devel@gnu.org To: Stefan Monnier Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Sun Sep 04 13:51:40 2022 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1oUoA8-0002DV-4F for ged-emacs-devel@m.gmane-mx.org; Sun, 04 Sep 2022 13:51:40 +0200 Original-Received: from localhost ([::1]:60322 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oUoA6-0006lu-SJ for ged-emacs-devel@m.gmane-mx.org; Sun, 04 Sep 2022 07:51:38 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:50566) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oUo4z-0004WI-En for emacs-devel@gnu.org; Sun, 04 Sep 2022 07:46:21 -0400 Original-Received: from 105.ip-51-83-47.eu ([51.83.47.105]:39544 helo=mail.phundrak.com) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oUo4x-0005Sz-DC for emacs-devel@gnu.org; Sun, 04 Sep 2022 07:46:21 -0400 Original-Received: from [127.0.0.1] (localhost [127.0.0.1]) by localhost (Mailerdaemon) with ESMTPSA id 7881DC0026; Sun, 4 Sep 2022 13:46:01 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=phundrak.com; s=dkim; t=1662291972; h=from:subject:date:message-id:to:cc:mime-version:content-type: in-reply-to:references; bh=FGEV30S3ELMcNNOdHbCDDeeyxn6IgvokXDXdPeTZbtA=; b=e0ku5WfiwIyv+S5A7o6iB6bdnJW/Zl+gpTgJ55aM+5e14B41Vf/wySPJQYBtfIDkyYkWsW M4wJJEX+igtPpQ2BdMpuGQeWPzq5luejSqtDHaT5FSSmzG3mr5LTEAszVBBaSZ8VfpX6aR ogOdSF5k7eCKmi6wRev5D/kO9SH9194= In-reply-to: X-Last-TLS-Session-Version: TLSv1.3 Received-SPF: pass client-ip=51.83.47.105; envelope-from=lucien@phundrak.com; helo=mail.phundrak.com X-Spam_score_int: -10 X-Spam_score: -1.1 X-Spam_bar: - X-Spam_report: (-1.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RDNS_DYNAMIC=0.982, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=no autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:294696 Archived-At: --===-=-= Content-Type: multipart/mixed; boundary="=-=-=" --=-=-= Content-Type: multipart/mixed; boundary="==-=-=" --==-=-= Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable > `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'=E2=80=99s 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) `---- =2D- Lucien =E2=80=9CPhundrak=E2=80=9D Cartier-Tilet (Fran=C3=A7ais) (English) Sent from GNU/Emacs --==-=-=-- --=-=-=-- --===-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQJIBAEBCAAyFiEEViv9D3b9mE+uAC3AvXeJ5wXLjcoFAmMUj+8UHGx1Y2llbkBw aHVuZHJhay5jb20ACgkQvXeJ5wXLjcohYA/9Ef30A67ph6WfE2Ag7ruQ7ikZKHFJ xnW7b6iKl5dz6rBkgysh9OfYB94XRLDKBllYQBCStiJBVkbml9BNphpLAPrRk5RF WGlVFun8ZwLdURdir+WpOzT7T+N2YH+4iMCzUg+s7+7wB3CwV067JIWZB7XyOcm3 GfwWO8NvnGC2z98CaXIR4vbOOsxNioAFe9l0hfgOyoQXTVhZoUDaMMyAGqQU5eLp tcatXkgNxWVlnZrvHBjrnajXQup3B124f8OrLyVftieuls44J98/OLV2GUO8K9Dv PJWHDMC7EFOmXJZOn4LknZGWR5hPuve4xzlI818bOk9d7tt0KPNY8NlQs6U15E5r F76DboE87f8XZ6yQon/Ti9pDotiaxGmseB1Vc6Go7i4Y+gFs4opeDLEHuKhzyHhY bE1wBV7cXfSQDKmHwIeeHCzvW2eiwms1cMW+S4TbERCTgs7YwA4OQY71k20VqbUu afVpkgQbIC01yK0j5zmybN8i2j+fnpJSqe6L4v+Z0DnltYUcoZVtjhEzUUIeXoOA UzIpCW+kqPUjxBf7Lv/uF2i1AFveTwdh50ja+csPjCizSvUJea6quirthmk0dTR1 0A8Gd9+CXa4LsJJLZE0nkpPOVuSrtB1FdEiT+qihP2EJMk/Ay8Dge3mJnBXZtcJt tI0XKpALuxzCk+M= =yVK6 -----END PGP SIGNATURE----- --===-=-=--