mirror of
git://git.sv.gnu.org/emacs.git
synced 2025-12-06 22:41:06 -08:00
Styled quotes in compiler warnings
* lisp/emacs-lisp/byte-run.el (byte-run--parse-body) (byte-run--unescaped-character-literals-warning): * lisp/emacs-lisp/bytecomp.el (byte-compile-initial-macro-environment) (byte-compile-form, bytecomp--warn-dodgy-eq-arg): * lisp/emacs-lisp/cconv.el (cconv--warn-unused-msg): * lisp/emacs-lisp/cl-macs.el (cl-defstruct): * lisp/emacs-lisp/easy-mmode.el (define-minor-mode): * lisp/emacs-lisp/eieio.el (defclass): * lisp/emacs-lisp/macroexp.el (macroexp--unfold-lambda) (macroexp--expand-all): * lisp/emacs-lisp/pcase.el (pcase--u1): * lisp/subr.el (when, unless, ignore-error, lsh, sit-for) (with-demoted-errors): Use format-message to ensure properly styled quotes in compiler warning messages.
This commit is contained in:
parent
cfc0e1cc02
commit
0e1b03bbb8
9 changed files with 46 additions and 37 deletions
|
|
@ -554,7 +554,7 @@ Return the compile-time value of FORM."
|
|||
,(macroexpand-all `(progn ,@body)
|
||||
macroexpand-all-environment)))
|
||||
(macroexp-warn-and-return
|
||||
"`with-suppressed-warnings' with empty body"
|
||||
(format-message "`with-suppressed-warnings' with empty body")
|
||||
nil '(empty-body with-suppressed-warnings) t warnings)))))
|
||||
"The default macro-environment passed to macroexpand by the compiler.
|
||||
Placing a macro here will cause a macro to have different semantics when
|
||||
|
|
@ -3445,7 +3445,7 @@ lambda-expression."
|
|||
(t "."))))
|
||||
(if (eq (car-safe (symbol-function (car form))) 'macro)
|
||||
(byte-compile-report-error
|
||||
(format "`%s' defined after use in %S (missing `require' of a library file?)"
|
||||
(format-message "`%s' defined after use in %S (missing `require' of a library file?)"
|
||||
(car form) form)))
|
||||
(if (and handler
|
||||
;; Make sure that function exists.
|
||||
|
|
@ -5524,8 +5524,8 @@ and corresponding effects."
|
|||
|
||||
(defun bytecomp--warn-dodgy-eq-arg (form type parenthesis)
|
||||
(macroexp-warn-and-return
|
||||
(format "`%s' called with literal %s that may never match (%s)"
|
||||
(car form) type parenthesis)
|
||||
(format-message "`%s' called with literal %s that may never match (%s)"
|
||||
(car form) type parenthesis)
|
||||
form (list 'suspicious (car form)) t))
|
||||
|
||||
(defun bytecomp--check-eq-args (form &optional a b &rest _ignore)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue