]> git.eshelyaron.com Git - emacs.git/commitdiff
Turn compiler macro defalias messages into warnings
authorMattias EngdegÄrd <mattiase@acm.org>
Mon, 7 Jul 2025 09:04:19 +0000 (11:04 +0200)
committerEshel Yaron <me@eshelyaron.com>
Thu, 24 Jul 2025 07:46:13 +0000 (09:46 +0200)
* lisp/emacs-lisp/bytecomp.el (byte-compile-file-form-defalias):
Turn messages into warnings to make them more visible to the user and
provide a source location (bug#78792).

(cherry picked from commit 0de646b6a16dac8cf185c32b02d4d575830c6a31)

lisp/emacs-lisp/bytecomp.el

index 70102be43180c8db5aab9014b2a4d5c17fbf62cd..cad274da5331d02b325332affaf880dc3e9312bf 100644 (file)
@@ -5209,8 +5209,10 @@ binding slots have been popped."
                   name macro arglist body rest)
            (when macro
              (if (null fun)
-                 (message "Macro %s unrecognized, won't work in file" name)
-               (message "Macro %s partly recognized, trying our luck" name)
+                 (byte-compile-warn-x
+                  name "Macro %s unrecognized, won't work in file" name)
+               (byte-compile-warn-x
+                name "Macro %s partly recognized, trying our luck" name)
                (push (cons name (eval fun lexical-binding))
                      byte-compile-macro-environment)))
            (byte-compile-keep-pending form))))