Fix type listp error when formatting buffers
Because `buffer-local-variables` may contain symbols (which represent locally unbound variables), not just sublists.
This commit is contained in:
parent
838f96a581
commit
4680f23d90
1 changed files with 2 additions and 1 deletions
|
@ -137,7 +137,8 @@ See `+format/buffer' for the interactive version of this function, and
|
||||||
(insert output)
|
(insert output)
|
||||||
;; Ensure this temp buffer _seems_ as much like the origin
|
;; Ensure this temp buffer _seems_ as much like the origin
|
||||||
;; buffer as possible.
|
;; buffer as possible.
|
||||||
(cl-loop for (var . val) in (buffer-local-variables origin-buffer)
|
(cl-loop for (var . val)
|
||||||
|
in (cl-remove-if-not #'listp (buffer-local-variables origin-buffer))
|
||||||
;; Making enable-multibyte-characters buffer-local
|
;; Making enable-multibyte-characters buffer-local
|
||||||
;; causes an error.
|
;; causes an error.
|
||||||
unless (eq var 'enable-multibyte-characters)
|
unless (eq var 'enable-multibyte-characters)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue