[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] master 74b5103: Fix last patch: ensure the return value of
From: |
Sam Steingold |
Subject: |
[Emacs-diffs] master 74b5103: Fix last patch: ensure the return value of tags-verify-table. |
Date: |
Fri, 24 Nov 2017 14:26:07 -0500 (EST) |
branch: master
commit 74b5103511dd41dbc0eda5ee848131eed6debc9a
Author: Sam Steingold <address@hidden>
Commit: Sam Steingold <address@hidden>
Fix last patch: ensure the return value of tags-verify-table.
* lisp/progmodes/etags.el (tags-verify-table): Since `(tags-table-mode)'
always return nil now that it is a derived mode, call
`verify-tags-table-function' explicitly.
---
lisp/progmodes/etags.el | 40 +++++++++++++++++++++-------------------
1 file changed, 21 insertions(+), 19 deletions(-)
diff --git a/lisp/progmodes/etags.el b/lisp/progmodes/etags.el
index 50a9f81..9b21ee6 100644
--- a/lisp/progmodes/etags.el
+++ b/lisp/progmodes/etags.el
@@ -436,25 +436,25 @@ Returns non-nil if it is a valid table."
(progn
(set-buffer (get-file-buffer file))
(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
- ;; or the user can say to revert.
- (not (or (let ((tail revert-without-query)
- (found nil))
- (while tail
- (if (string-match (car tail) buffer-file-name)
- (setq found t))
- (setq tail (cdr tail)))
- found)
- tags-revert-without-query
- (yes-or-no-p
- (format "Tags file %s has changed, read new contents?
"
- file)))))
- (and verify-tags-table-function
- (funcall verify-tags-table-function))
+ (unless (or (verify-visited-file-modtime (current-buffer))
+ ;; Decide whether to revert the file.
+ ;; revert-without-query can say to revert
+ ;; or the user can say to revert.
+ (not (or (let ((tail revert-without-query)
+ (found nil))
+ (while tail
+ (if (string-match (car tail) buffer-file-name)
+ (setq found t))
+ (setq tail (cdr tail)))
+ found)
+ tags-revert-without-query
+ (yes-or-no-p
+ (format "Tags file %s has changed, read new
contents? "
+ file)))))
(revert-buffer t t)
- (tags-table-mode)))
+ (tags-table-mode))
+ (and verify-tags-table-function
+ (funcall verify-tags-table-function)))
(when (file-exists-p file)
(let* ((buf (find-file-noselect file))
(newfile (buffer-file-name buf)))
@@ -467,7 +467,9 @@ Returns non-nil if it is a valid table."
;; Only change buffer now that we're done using potentially
;; buffer-local variables.
(set-buffer buf)
- (tags-table-mode)))))
+ (tags-table-mode)
+ (and verify-tags-table-function
+ (funcall verify-tags-table-function))))))
;; 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
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Emacs-diffs] master 74b5103: Fix last patch: ensure the return value of tags-verify-table.,
Sam Steingold <=