Fix potential (goto-char nil) in byte-compile-warning-prefix

* lisp/emacs-lisp/bytecomp.el (byte-compile-warning-prefix): Replace a wrong
'or' form involving OFFSET with simply OFFSET.  This prevents OFFSET from
possibly being nil in the first branch of the containing `if' form.
This commit is contained in:
Alan Mackenzie 2022-06-20 18:31:05 +00:00
parent 54e3509771
commit 4ae315f7c3

View file

@ -1246,8 +1246,7 @@ Order is by depth-first search."
load-file-name dir)))
(t "")))
(offset (byte-compile--warning-source-offset))
(pos (if (and byte-compile-current-file
(or offset (not symbols-with-pos-enabled)))
(pos (if (and byte-compile-current-file offset)
(with-current-buffer byte-compile-current-buffer
(let (new-l new-c)
(save-excursion