Function: tags-table-check-computed-list
tags-table-check-computed-list is a byte-compiled function defined in
etags.el.gz.
Signature
(tags-table-check-computed-list)
Documentation
Compute tags-table-computed-list from tags-table-list if necessary.
Source Code
;; Defined in /usr/src/emacs/lisp/progmodes/etags.el.gz
(defun tags-table-check-computed-list ()
"Compute `tags-table-computed-list' from `tags-table-list' if necessary."
(let ((expanded-list (mapcar #'tags-expand-table-name tags-table-list)))
(or (equal tags-table-computed-list-for expanded-list)
;; The list (or default-directory) has changed since last computed.
(let* ((compute-for (mapcar #'copy-sequence expanded-list))
(tables (copy-sequence compute-for)) ;Mutated in the loop.
(computed nil)
table-buffer)
(while tables
(setq computed (cons (car tables) computed)
table-buffer (get-file-buffer (car tables)))
(if (and table-buffer
;; There is a buffer visiting the file. Now make sure
;; it is initialized as a tag table buffer.
(save-excursion
(tags-verify-table (buffer-file-name table-buffer))))
(with-current-buffer table-buffer
;; Needed so long as etags-tags-included-tables
;; does not save-excursion.
(save-excursion
(if (tags-included-tables)
;; Insert the included tables into the list we
;; are processing.
(setcdr tables (nconc (mapcar #'tags-expand-table-name
(tags-included-tables))
(cdr tables))))))
;; This table is not in core yet. Insert a placeholder
;; saying we must read it into core to check for included
;; tables before searching the next table in the list.
(setq computed (cons t computed)))
(setq tables (cdr tables)))
;; Record the tags-table-list value (and the context of the
;; current directory) we computed from.
(setq tags-table-computed-list-for compute-for
tags-table-computed-list (nreverse computed))))))