Fix warning messages about lexbind cookie in subdirs.el
* lisp/files.el (internal--get-default-lexical-binding): Don't log a warning message when lexbind warning is disabled, and 'display-warning' is unavailable or signals an error.
This commit is contained in:
parent
ebaf424126
commit
e0c7b6e31e
1 changed files with 4 additions and 1 deletions
|
@ -4314,7 +4314,10 @@ for more information."
|
|||
;; fail (e.g. not yet defined, or can't be (auto)loaded),
|
||||
;; so use a simple fallback that won't get in the way.
|
||||
(error
|
||||
(message "Missing `lexical-binding' cookie in %S" source)))))
|
||||
;; But not if this particular warning is disabled.
|
||||
(unless (equal warning-inhibit-types
|
||||
'((files missing-lexbind-cookie)))
|
||||
(message "Missing `lexical-binding' cookie in %S" source))))))
|
||||
(default-toplevel-value 'lexical-binding)))
|
||||
|
||||
(setq internal--get-default-lexical-binding-function
|
||||
|
|
Loading…
Add table
Reference in a new issue