[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#47843: 28.0.50; Setting enable-local-variables to nil *appears* to i
From: |
Lars Ingebrigtsen |
Subject: |
bug#47843: 28.0.50; Setting enable-local-variables to nil *appears* to inhibit lexical-binding (but doesn't) |
Date: |
Thu, 06 May 2021 11:04:56 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) |
Stefan Monnier <monnier@iro.umontreal.ca> writes:
> Indeed, an exception would be welcome for that var, otherwise there will
> be bad surprises. We could probably have a variable holding a list of
> vars that always obey file-local settings.
Poking around for a couple of minutes, would the right way to implement
this be to always call `hack-local-variables' in `set-auto-mode' here?
;; hack-local-variables checks local-enable-local-variables etc, but
;; we might as well be explicit here for the sake of clarity.
(and (not done)
enable-local-variables
local-enable-local-variables
try-locals
(setq mode (hack-local-variables t))
But then filter out all variables except the ones in this new list in
`hack-local-variables-filter' (if `enable-local-variables' is nil)?
The new list could be called... uhm...
`permanently-enabled-local-variables'?
--
(domestic pets only, the antidote for overdose, milk.)
bloggy blog: http://lars.ingebrigtsen.no