* lisp/files.el (hack-one-local-variable): Allow add-function in eval:

Fixes: bug#49163
This commit is contained in:
Stefan Monnier 2021-06-27 18:01:13 -04:00
parent fe81c04489
commit 9060fbd3b5

View file

@ -4041,7 +4041,7 @@ already the major mode."
('eval
(pcase val
(`(add-hook ',hook . ,_) (hack-one-local-variable--obsolete hook)))
(save-excursion (eval val)))
(save-excursion (eval val t)))
(_
(hack-one-local-variable--obsolete var)
;; Make sure the string has no text properties.