Mercurial > emacs
changeset 86244:d6eda104caa6
(check-declare-verify): Tweak regexp for end of function-name. Handle
define-derived-mode.
author | Glenn Morris <rgm@gnu.org> |
---|---|
date | Tue, 20 Nov 2007 03:53:23 +0000 |
parents | 4d615a83cee2 |
children | 26cc264a4964 |
files | lisp/emacs-lisp/check-declare.el |
diffstat | 1 files changed, 8 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/lisp/emacs-lisp/check-declare.el Tue Nov 20 00:57:10 2007 +0000 +++ b/lisp/emacs-lisp/check-declare.el Tue Nov 20 03:53:23 2007 +0000 @@ -86,14 +86,18 @@ (with-temp-buffer (insert-file-contents fnfile) ;; defsubst's don't _have_ to be known at compile time. - (setq re (format "^[ \t]*(def\\(un\\|subst\\)[ \t]+%s\\>" + (setq re (format "^[ \t]*(\\(def\\(?:un\\|subst\\|\ +ine-derived-mode\\)\\)\[ \t]+%s\\([ \t;]+\\|$\\)" (regexp-opt (mapcar 'cadr fnlist) t))) (while (re-search-forward re nil t) (skip-chars-forward " \t\n") (setq fn (match-string 2) - sig (if (looking-at "\\((\\|nil\\)") - (byte-compile-arglist-signature - (read (current-buffer)))) + sig (if (string-equal "define-derived-mode" + (match-string 1)) + '(0 . 0) + (if (looking-at "\\((\\|nil\\)") + (byte-compile-arglist-signature + (read (current-buffer))))) ;; alist of functions and arglist signatures. siglist (cons (cons fn sig) siglist))))) (dolist (e fnlist)