# HG changeset patch # User Richard M. Stallman # Date 758272907 0 # Node ID 2b3d2ea74ce10726c0d92eeca2cb59cb2715e0ad # Parent fd7524d61a8d76da2745e5139c8d25640f586096 (byte-compile-condition-case): Disable warning about symbol not naming a condition. Allow a list of condition names. diff -r fd7524d61a8d -r 2b3d2ea74ce1 lisp/emacs-lisp/bytecomp.el --- a/lisp/emacs-lisp/bytecomp.el Tue Jan 11 05:49:41 1994 +0000 +++ b/lisp/emacs-lisp/bytecomp.el Tue Jan 11 07:21:47 1994 +0000 @@ -2681,16 +2681,24 @@ (while clauses (let* ((clause (car clauses)) (condition (car clause))) - (cond ((not (symbolp condition)) + (cond ((not (or (symbolp condition) + (and (listp condition) + (let ((syms condition) (ok t)) + (while syms + (if (not (symbolp (car syms))) + (setq ok nil)) + (setq syms (cdr syms))) + ok)))) (byte-compile-warn - "%s is not a symbol naming a condition (in condition-case)" + "%s is not a condition name or list of such (in condition-case)" (prin1-to-string condition))) - ((not (or (eq condition 't) - (and (stringp (get condition 'error-message)) - (consp (get condition 'error-conditions))))) - (byte-compile-warn - "%s is not a known condition name (in condition-case)" - condition))) +;; ((not (or (eq condition 't) +;; (and (stringp (get condition 'error-message)) +;; (consp (get condition 'error-conditions))))) +;; (byte-compile-warn +;; "%s is not a known condition name (in condition-case)" +;; condition)) + ) (setq compiled-clauses (cons (cons condition (byte-compile-top-level-body