From d0b273a546019ca3efd9ce487ce0cc270d8d8a55 Mon Sep 17 00:00:00 2001 From: Kévin Le Gouguec Date: Sun, 17 Mar 2024 12:51:53 +0100 Subject: Fix broken macro MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit IIUC the previous version ran customizations immediately during expansion (ultimately expanding to the last customize-set-variable value), instead of generating forms that would run those customizations at appropriate times. Guess I never run Emacs <29 😐 --- .emacs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.emacs b/.emacs index 2e0c170..c8c2260 100644 --- a/.emacs +++ b/.emacs @@ -19,8 +19,9 @@ (if (fboundp 'setopt) (defalias 'my/setopt 'setopt) (defmacro my/setopt (&rest pairs) - (while pairs - (customize-set-variable (pop pairs) (pop pairs))))) + `(let ((pairs (quote ,pairs))) + (while pairs + (customize-set-variable (pop pairs) (pop pairs)))))) ;; Some list variables I don't set via Custom. I can't tell Custom ;; "add this element, take those two away": I need to "set in stone" -- cgit v1.2.3