all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Kevin Ryde <user42@zip.com.au>
Subject: info-look.el better autoconf support
Date: Thu, 22 May 2003 09:58:27 +1000	[thread overview]
Message-ID: <87he7nhmxo.fsf@zip.com.au> (raw)

[-- Attachment #1: Type: text/plain, Size: 753 bytes --]

Some tweaks to better support autoconf 2.57.

	* 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.

In an autoconf-mode buffer this make C-h C-i able to lookup more
things, like AH_VERBATIM, AU_DEFUN, m4_defn, AT_CHECK.

Unfortunately currently AT_CHECK and other Autotest index entries fail
on account of a period in the node name.  (Both info-look.el or
pressing Ret on an entry fail.)  Unless emacs is going to relax its
requirements about this I guess it should be fixed in autoconf.


[-- Attachment #2: info-look.el.autoconf-mode.diff --]
[-- Type: text/plain, Size: 2671 bytes --]

*** info-look.el.~1.33.~	Thu May 22 08:52:56 2003
--- info-look.el	Thu May 22 09:56:53 2003
*************** (info-lookup-maybe-add-help
*** 682,694 ****
  (info-lookup-maybe-add-help
   :mode 'autoconf-mode
   :regexp "A[CM]_[_A-Z0-9]+"
!  :doc-spec '(("(autoconf)Autoconf Macro Index" "AC_"
  	      "^[ \t]+- \\(Macro\\|Variable\\): .*\\<" "\\>")
! 	     ("(automake)Macro and Variable Index" nil
! 	      "^[ \t]*`" "'")
! 	     ;; These are for older versions (probably pre autoconf 2.5x):
  	     ("(autoconf)Macro Index" "AC_"
  	      "^[ \t]+- \\(Macro\\|Variable\\): .*\\<" "\\>")
  	     ("(automake)Macro and Variable Index" nil
  	      "^[ \t]*`" "'"))
   ;; Autoconf symbols are M4 macros.  Thus use M4's parser.
--- 682,718 ----
  (info-lookup-maybe-add-help
   :mode 'autoconf-mode
   :regexp "A[CM]_[_A-Z0-9]+"
!  :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\\): .*\\<" "\\>")
!              ;; 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.

[-- Attachment #3: Type: text/plain, Size: 142 bytes --]

_______________________________________________
Emacs-devel mailing list
Emacs-devel@gnu.org
http://mail.gnu.org/mailman/listinfo/emacs-devel

                 reply	other threads:[~2003-05-21 23:58 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87he7nhmxo.fsf@zip.com.au \
    --to=user42@zip.com.au \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.