GNU bug report logs - #74964
31.0.50 master; .dir-locals.el vars does not work with changing major mode

Previous Next

Package: emacs;

Reported by: Yikai Zhao <yikai <at> z1k.dev>

Date: Thu, 19 Dec 2024 07:55:02 UTC

Severity: normal

Found in version 31.0.50

Done: Stefan Monnier <monnier <at> iro.umontreal.ca>

Bug is archived. No further changes may be made.

Full log


Message #28 received at 74964-done <at> debbugs.gnu.org (full text, mbox):

From: Yikai Zhao <yikai <at> z1k.dev>
To: Stefan Monnier <monnier <at> iro.umontreal.ca>
Cc: Eli Zaretskii <eliz <at> gnu.org>, rpluim <at> gmail.com, 74964-done <at> debbugs.gnu.org
Subject: Re: bug#74964: 31.0.50 master; .dir-locals.el vars does not work with
 changing major mode
Date: Thu, 16 Jan 2025 16:29:40 +0800
Hi Stefan,

Sorry to bring this back again.

The original issue is indeed fixed, however there's another related
issue remaining. With the following .dir-locals.el code:

((nil . ((my/test . "test")
         (eval . (setq-local my/test2 "test2"))))
 (c-mode . ((eval . (when (eq major-mode 'c-mode)
                      (c++-mode))))))

The `my/test` variable will be set after your fix. But the `my/test2`
variable is still not set.

On Sun, Jan 5, 2025 at 11:05 PM Stefan Monnier <monnier <at> iro.umontreal.ca> wrote:
>
> >> This patch does fix the issue for me. Thanks.
>
> Thank you for confirming!
>
> > Thanks for testing.  Stefan, please install, and thanks.
>
> Closing,
>
>
>         Stefan
>




This bug report was last modified 122 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.