From: Juanma Barranquero Date: Sun, 25 May 2003 21:08:21 +0000 (+0000) Subject: (autoconf-mode setups): Recognise AH_ and AU_ entries in "(autoconf)Autoconf X-Git-Tag: ttn-vms-21-2-B4~9937 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=01e1a81920aa4e805b1c2ab0e13472094e991979;p=emacs.git (autoconf-mode setups): Recognise AH_ and AU_ entries in "(autoconf)Autoconf Macro Index". Add "(autoconf)M4 Macro Index" and "(autoconf)Autotest Macro Index". Remove duplicate copy of "(automake)Macro and Variable Index". Keep automake after all autoconf possibilities, so as to prefer those. --- diff --git a/lisp/ChangeLog b/lisp/ChangeLog index c5a6800cce9..4b552b253c6 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,11 @@ +2003-05-25 Kevin Ryde + + * info-look.el (autoconf-mode setups): Recognise AH_ and AU_ entries + in "(autoconf)Autoconf Macro Index". Add "(autoconf)M4 Macro Index" + and "(autoconf)Autotest Macro Index". Remove duplicate copy of + "(automake)Macro and Variable Index". Keep automake after all + autoconf possibilities, so as to prefer those. + 2003-05-25 Nick Roberts * gdb-ui.el (gdb-info-breakpoints-custom, gdb-assembler-custom): diff --git a/lisp/info-look.el b/lisp/info-look.el index e81d33e65f2..afdf123ecb0 100644 --- a/lisp/info-look.el +++ b/lisp/info-look.el @@ -682,13 +682,37 @@ Return nil if there is nothing appropriate in the buffer near point." (info-lookup-maybe-add-help :mode 'autoconf-mode :regexp "A[CM]_[_A-Z0-9]+" - :doc-spec '(("(autoconf)Autoconf Macro Index" "AC_" + :doc-spec '(;; Autoconf Macro Index entries are without an "AC_" prefix, + ;; but with "AH_" or "AU_" for those. So add "AC_" if there + ;; isn't already an "A._". + ("(autoconf)Autoconf Macro Index" + (lambda (item) + (if (string-match "^A._" item) item (concat "AC_" item))) "^[ \t]+- \\(Macro\\|Variable\\): .*\\<" "\\>") - ("(automake)Macro and Variable Index" nil - "^[ \t]*`" "'") - ;; These are for older versions (probably pre autoconf 2.5x): + ;; M4 Macro Index entries are without "AS_" prefixes, and + ;; mostly without "m4_" prefixes. "dnl" is an exception, not + ;; wanting any prefix. So AS_ is added back to upper-case + ;; names, m4_ to others which don't already an m4_. + ("(autoconf)M4 Macro Index" + (lambda (item) + (let ((case-fold-search nil)) + (cond ((or (string-equal item "dnl") + (string-match "^m4_" item)) + item) + ((string-match "^[A-Z0-9_]+$" item) + (concat "AS_" item)) + (t + (concat "m4_" item))))) + "^[ \t]+- Macro: .*\\<" "\\>") + ;; Autotest Macro Index entries are without "AT_". + ("(autoconf)Autotest Macro Index" "AT_" + "^[ \t]+- Macro: .*\\<" "\\>") + ;; This is for older versions (probably pre autoconf 2.5x): ("(autoconf)Macro Index" "AC_" "^[ \t]+- \\(Macro\\|Variable\\): .*\\<" "\\>") + ;; Automake has index entries for its notes on various autoconf + ;; macros (eg. AC_PROG_CC). Ensure this is after the autoconf + ;; index, so as to prefer the autoconf docs. ("(automake)Macro and Variable Index" nil "^[ \t]*`" "'")) ;; Autoconf symbols are M4 macros. Thus use M4's parser.