Hi Morgan, you are right in the base message: someone should revisit why these setters and getters are in org-mode, which emacs versions need them, etc. etc.
As you see, I mark this "for the brave" to collect experience different than mine. Why have I started with this pair? Basically because they feel redundant and I would like to find a use case that justifies having both. If you read the setter function, it adds the SNIPPET? flag as t if omitted and then writes the resulting value in the variable and then repeats the procedure when accessing the variable. My intuition is that we only need to add the SNIPPET? flag when reading the variable and that the getter should be enough. 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. 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? Best, /PA On Wed, 21 Oct 2026 at 21:24, Morgan Smith <[email protected]> wrote: > "Pedro A. Aranda" <[email protected]> writes: > > > PS: Similar messages appear when editing the manual and > > ORG-NEWS... > > > > Best, /PA > > > > On 18/10/26 8:24, Pedro A. Aranda wrote: > >> Hi attached is a small patch for the brave. Since some of us > >> are already experimenting with emacs-32, I'd need your help in > >> testing this. I have observed that some custom variables have > >> getter and setter functions that do the same and thus seem > >> redundant. This is the case with > >> org-latex-default-packages-alist and org-latex- > >> packages-alist. So I'm testing a solution where I only use the > >> getter function. > >> Since it may be possible to extrapolate this to more custom > >> variables, I'd ask you to test this patch and tell us if it > >> breaks something. All emacs version welcome :-) Thanks a ton, > >> /PA > > Looking at the history of 'org-set-packages-alist' brings us to > commit f9ea6c61e. This commit message mentions issues with > autoloading and let-binding. The commit message also links to > these resources: > > bug#54399 > https://lists.gnu.org/archive/html/emacs-orgmode/2022-03/msg00085.html > https://lists.gnu.org/archive/html/emacs-orgmode/2022-06/msg00226.html > > I haven't looked at any of those resources but someone probably > should to see why this was put there in the first place. > -- 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...
