mirror of
https://github.com/doomemacs/doomemacs
synced 2025-08-01 12:17:25 -05:00
Log unsafe eval forms in file/dir local variables
This commit is contained in:
@ -37,7 +37,11 @@ employed so that flycheck still does *some* helpful linting.")
|
||||
(pcase-dolist (`(,var . ,val) variables)
|
||||
(cond ((memq var ignored-local-variables))
|
||||
((memq var '(mode unibyte coding)))
|
||||
((eq var 'eval))
|
||||
((eq var 'eval)
|
||||
(and enable-local-eval
|
||||
(not (or (hack-one-local-variable-eval-safep val)
|
||||
(safe-local-variable-p var val)))
|
||||
(message "Ignoring unsafe form in file local variable: %S" val)))
|
||||
((not (safe-local-variable-p var val))
|
||||
(message "Ignoring unsafe file local variable: %S" var))
|
||||
((risky-local-variable-p var val)
|
||||
|
Reference in New Issue
Block a user