Hi again, One variable a day... ;-)
attached is a patch that silences org-footnote-section in emacs32. Basically what I'm doing is relying on Emacs Lisp functions that work on emacs-32 and adopt the new calling convention. This silences the warning in this case. I have tested this with emacs-31 too and everything seems to work as expected. The only "quirk" is a warning about an unused local variable during make compile Once again, testing will help us overcome this :-) /PA On Fri, 23 Oct 2026 at 07:07, Pedro Andres Aranda Gutierrez < [email protected]> wrote: > Hi, > > On Thu, 22 Oct 2026 at 23:01, Morgan Smith <[email protected]> > wrote: > >> Pedro Andres Aranda Gutierrez <[email protected]> writes: >> >> > As a side effect, I get rid of the setopt-local warning on Emacs 32, >> which I'm >> > test driving because it is currently starting to provide a nice internal >> > refactor engine which is quite convenient when hacking on ox-latex and >> > ox-beamer. >> >> A refactor engine? What exactly are you referring too? I am quite >> intrigued. > > > I got intrigued too, when I read: > > https://lists.gnu.org/archive/html/emacs-devel/2026-10/msg00259.html > > and after an initial glitch which affected by editing LaTeX, now > everything is going nicely. I had a function of my own to rename variables > inside am Elisp Function, but this stuff is much more general. > >> > >> > That said, there are additional motivations to start rethinking this: >> > 1. simplification: one function less to take care of, and a very tricky >> one >> > because it dives into someone obscure details of Emacs Lisp: lexical >> bindings, >> > etc. >> > 2. more in general: I already experience similar nasty messages when >> working on >> > the Org manual and ORG-NEWS. Am I the only one? >> >> I would love to simplify the code-base and yes I am drowning in these >> nasty messages. I think I caught a glimpse of Ihor suffering as well at >> the last meetup. >> >> This is an important issue that we should solve. I was just trying to >> add some data to this report that might help resolve it. > > Yes, right and after looking at the commits, my impression is that they > did what I did with the #' ;-) > And from my perspective it went well, because now everything in the LaTeX > exporter menu is a function, > but maybe I overdid.... > So, this time, instead of trying to solve everything in a blow, I think I > identified one variable where we can discuss if the simplification makes > sense or not. > > Maybe I'll get around to solving it myself but no promises :P >> > > :-) Could we go step by step? Please take a look at what I propose in the > scope I propose and tell me whether it makes sense or not... > > > Thanks, /PA > > -- > Fragen sind nicht da, um beantwortet zu werden, > Fragen sind da um gestellt zu werden > Georg Kreisler > > "Sagen's Paradeiser" (ORF: Als Radiohören gefährlich war) => write BE! > Year 2 of the New Koprocracy > > *IA: onomatopeya del rebuznar* > > This was produced by a human (implied virtues and weaknesses acknowledged) > Don't feed your ArtStup (SKA AI) with this. It won't make YOU smarter... > -- Fragen sind nicht da, um beantwortet zu werden, Fragen sind da um gestellt zu werden Georg Kreisler "Sagen's Paradeiser" (ORF: Als Radiohören gefährlich war) => write BE! Year 2 of the New Koprocracy *IA: onomatopeya del rebuznar* This was produced by a human (implied virtues and weaknesses acknowledged) Don't feed your ArtStup (SKA AI) with this. It won't make YOU smarter...
diff --git a/lisp/org-footnote.el b/lisp/org-footnote.el index 5603adfe6..43a48f670 100644 --- a/lisp/org-footnote.el +++ b/lisp/org-footnote.el @@ -113,8 +113,9 @@ (defcustom org-footnote-section "Footnotes" `\\[universal-argument] \\[org-element-cache-reset]'" :group 'org-footnote :initialize 'custom-initialize-default - :set (lambda (var val) - (set-default-toplevel-value var val) + :set (lambda (var val &optional local) + (let ((custom-local-buffer nil)) + (custom-set-default var val)) (when (fboundp 'org-element-cache-reset) (org-element-cache-reset 'all))) :type '(choice
