Mercurial > emacs
changeset 66277:3f62e030a058
(tags-table-mode): New function.
(tags-verify-table): Replace initialize-new-tags-table with tags-table-mode.
author | Juri Linkov <juri@jurta.org> |
---|---|
date | Fri, 21 Oct 2005 08:48:04 +0000 |
parents | e74ff0edf071 |
children | 8926d6f2f267 |
files | lisp/progmodes/etags.el |
diffstat | 1 files changed, 11 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/lisp/progmodes/etags.el Fri Oct 21 08:27:14 2005 +0000 +++ b/lisp/progmodes/etags.el Fri Oct 21 08:48:04 2005 +0000 @@ -274,6 +274,14 @@ (run-hook-with-args-until-success 'tags-table-format-functions)) ;;;###autoload +(defun tags-table-mode () + "Major mode for tags table file buffers." + (interactive) + (setq major-mode 'tags-table-mode) + (setq mode-name "Tags Table") + (initialize-new-tags-table)) + +;;;###autoload (defun visit-tags-table (file &optional local) "Tell tags commands to use tags table file FILE. FILE should be the name of a file created with the `etags' program. @@ -415,7 +423,7 @@ ;; having changed since we last used it. (let (win) (set-buffer (get-file-buffer file)) - (setq win (or verify-tags-table-function (initialize-new-tags-table))) + (setq win (or verify-tags-table-function (tags-table-mode))) (if (or (verify-visited-file-modtime (current-buffer)) ;; Decide whether to revert the file. ;; revert-without-query can say to revert @@ -434,7 +442,7 @@ (and verify-tags-table-function (funcall verify-tags-table-function)) (revert-buffer t t) - (initialize-new-tags-table))) + (tags-table-mode))) (and (file-exists-p file) (progn (set-buffer (find-file-noselect file)) @@ -446,7 +454,7 @@ (setcar tail buffer-file-name)) (if (eq file tags-file-name) (setq tags-file-name buffer-file-name)))) - (initialize-new-tags-table))))) + (tags-table-mode))))) ;; Subroutine of visit-tags-table-buffer. Search the current tags tables ;; for one that has tags for THIS-FILE (or that includes a table that