emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

master 5fb9a03: Allow inhibiting warnings about obsolete macros again


From: Lars Ingebrigtsen
Subject: master 5fb9a03: Allow inhibiting warnings about obsolete macros again
Date: Tue, 30 Nov 2021 08:38:25 -0500 (EST)

branch: master
commit 5fb9a033f896440ffddeb475ee655413eb7f03f2
Author: Lars Ingebrigtsen <larsi@gnus.org>
Commit: Lars Ingebrigtsen <larsi@gnus.org>

    Allow inhibiting warnings about obsolete macros again
    
    * lisp/emacs-lisp/macroexp.el (macroexp-macroexpand): Inhibit
    warning if requested (bug#50984).
---
 lisp/emacs-lisp/macroexp.el | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)

diff --git a/lisp/emacs-lisp/macroexp.el b/lisp/emacs-lisp/macroexp.el
index 1e4fdd1..66c276e 100644
--- a/lisp/emacs-lisp/macroexp.el
+++ b/lisp/emacs-lisp/macroexp.el
@@ -216,10 +216,11 @@ is executed without being compiled first."
         (let* ((fun (car form))
                (obsolete (get fun 'byte-obsolete-info)))
           (macroexp-warn-and-return
-           (macroexp--obsolete-warning
-            fun obsolete
-            (if (symbolp (symbol-function fun))
-                "alias" "macro"))
+           (and (byte-compile-warning-enabled-p 'obsolete fun)
+                (macroexp--obsolete-warning
+                 fun obsolete
+                 (if (symbolp (symbol-function fun))
+                     "alias" "macro")))
            new-form 'obsolete))
       new-form)))
 



reply via email to

[Prev in Thread] Current Thread [Next in Thread]