* lisp/files-x.el (hack-connection-local-variables):
Bind `enable-local-variables', instead of re-declaring
`safe-local-variable-p'.
;;; Code:
(eval-when-compile (require 'subr-x)) ; for string-trim-right
-(eval-when-compile (require 'cl-lib)) ; for cl-letf
\f
;;; Commands to add/delete file-local/directory-local variables.
;; Push them to `file-local-variables-alist'. Connection-local
;; variables do not appear from external files. So we can regard
;; them as safe.
- (cl-letf (((symbol-function 'safe-local-variable-p) (lambda (_sym _val) t)))
+ (let ((enable-local-variables :all))
(hack-local-variables-filter connection-local-variables-alist nil))))
;;;###autoload