[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Issues with major-mode-remap-defaults
From: |
Tim Ruffing |
Subject: |
Issues with major-mode-remap-defaults |
Date: |
Mon, 13 Jan 2025 23:27:11 +0100 |
Emacs 30.0.93 (and maybe earlier versions of Emacs 30) initialize
major-mode-remap-defaults with mappings from the built-in modes to the
AUCTeX modes:
See lisp/textmodes/tex-mode.el around line 1041
(Or, brace yourself, click that link to GitHub:
https://github.com/emacs-mirror/emacs/blob/68bcabf58afddb377d172857ce7648ad3ff09618/lisp/textmodes/tex-mode.el#L1041-L1045
)
AUCTeX does the opposite. This means that after loading AUXTeX, we'll
get this "funny" value for major-mode-remap-defaults:
((doctex-mode . docTeX-mode)
(latex-mode . LaTeX-mode)
(texinfo-mode . Texinfo-mode)
(plain-tex-mode . plain-TeX-mode)
(tex-mode . TeX-tex-mode)
(LaTeX-mode . latex-mode)
(plain-TeX-mode . plain-tex-mode)
(TeX-mode . tex-mode))
Now this is full chaos. If you set latex-mode in auto-mode-alist,
you'll get LaTeX-mode, and the other way around. (I mean, at least
Emacs stops after one remapping and doesn't enter infinite loop.)
I think AUCTeX should just remove the built-in mappings, which are
intended for the case where AUCTeX is not installed. Note that even
AUCTeX adds LaTeX-mode entries to auto-mode-alist that will now be
redirected to latex-mode.
Best,
Tim
PS: I haven't subscribed to the list, please reply to my address
directly if you want to keep me in the loop.
- Issues with major-mode-remap-defaults,
Tim Ruffing <=
- Re: Issues with major-mode-remap-defaults, Arash Esbati, 2025/01/14
- Re: Issues with major-mode-remap-defaults, Tim Ruffing, 2025/01/14
- Re: Issues with major-mode-remap-defaults, Arash Esbati, 2025/01/14
- Re: Issues with major-mode-remap-defaults, Ikumi Keita, 2025/01/14
- Re: Issues with major-mode-remap-defaults, Colin Baxter, 2025/01/14
- Re: Issues with major-mode-remap-defaults, Ikumi Keita, 2025/01/14
- Re: Issues with major-mode-remap-defaults, Colin Baxter, 2025/01/14
- Re: Issues with major-mode-remap-defaults, Arash Esbati, 2025/01/14
- Re: Issues with major-mode-remap-defaults, Ikumi Keita, 2025/01/14
- Re: Issues with major-mode-remap-defaults, Arash Esbati, 2025/01/14