emacs-elpa-diffs
[Top][All Lists]
Advanced

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

[elpa] master 99de0ba 09/11: Fix comp warnings


From: Artur Malabarba
Subject: [elpa] master 99de0ba 09/11: Fix comp warnings
Date: Thu, 18 Jun 2015 17:30:27 +0000

branch: master
commit 99de0ba2e0d1c03302a2d07238c354b87427ba6d
Author: Artur Malabarba <address@hidden>
Commit: Artur Malabarba <address@hidden>

    Fix comp warnings
---
 names.el |   17 +++++++++--------
 1 files changed, 9 insertions(+), 8 deletions(-)

diff --git a/names.el b/names.el
index 1695a21..535050f 100644
--- a/names.el
+++ b/names.el
@@ -82,7 +82,8 @@ it will set PROP."
     (defalias 'names--compat-macrop #'macrop)
   (defun names--compat-macrop (object)
     "Non-nil if and only if OBJECT is a macro."
-    (let ((def (indirect-function object t)))
+    (let ((def (or (ignore-errors (indirect-function object t))
+                   (ignore-errors (indirect-function object)))))
       (when (consp def)
         (or (eq 'macro (car def))
             (and (names--autoloadp def) (memq (nth 4 def) '(macro t))))))))
@@ -765,6 +766,10 @@ returns nil."
            (and (names--keyword :global)
                 (boundp (names--prepend sbl))))))
 
+(defvar names--verbose nil
+  "If non-nil, verbose message are printed regardless of the :verbose keyword.
+Use this to easily turn on verbosity during tests.")
+
 (defun names--args-of-function-or-macro (function args macro)
   "Namespace FUNCTION's arguments ARGS, with special treatment if MACRO is 
non-nil."
   (if macro
@@ -857,14 +862,10 @@ phenomenally. So we hack into edebug instead."
     (symbol-function 'message))
   "Where names stores `message's definition while overriding it.")
 
-(defvar names--verbose nil
-  "If non-nil, verbose message are printed regardless of the :verbose keyword.
-Use this to easily turn on verbosity during tests.")
-
-(defun names--edebug-message (&rest _)
+(defun names--edebug-message (&rest args)
   (if (or (names--keyword :verbose) names--verbose)
-      (apply names--message-backup _)
-    (when _ (apply 'format _))))
+      (apply names--message-backup args)
+    (when args (apply #'format args))))
 
 (defun names--edebug-make-enter-wrapper (forms)
   (setq edebug-def-name



reply via email to

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