* lisp/emacs-lisp/bytecomp.el: Don't warn for repeated _ args
(byte-compile-check-lambda-list): Skip warnings of repeated arg for those that are declared as unused anyway.
This commit is contained in:
parent
9b7eed33f9
commit
b6eccad06c
1 changed files with 3 additions and 1 deletions
|
@ -2859,7 +2859,9 @@ If FORM is a lambda or a macro, byte-compile it as a function."
|
|||
((eq arg '&optional)
|
||||
(when (memq '&optional (cdr list))
|
||||
(error "Duplicate &optional")))
|
||||
((memq arg vars)
|
||||
((and (memq arg vars)
|
||||
;; Allow repetitions for unused args.
|
||||
(not (string-match "\\`_" (symbol-name arg))))
|
||||
(byte-compile-warn "repeated variable %s in lambda-list" arg))
|
||||
(t
|
||||
(push arg vars))))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue