Function: speedbar-fetch-dynamic-tags

speedbar-fetch-dynamic-tags is a byte-compiled function defined in speedbar.el.gz.

Signature

(speedbar-fetch-dynamic-tags FILE)

Documentation

Return a list of tags generated dynamically from FILE.

This uses the entries in speedbar-dynamic-tags-function-list to find the proper tags. It is up to each of those individual functions to do caching and flushing if appropriate.

Source Code

;; Defined in /usr/src/emacs/lisp/speedbar.el.gz
;;; Tag Management -- List of expanders:
;;
(defun speedbar-fetch-dynamic-tags (file)
  "Return a list of tags generated dynamically from FILE.
This uses the entries in `speedbar-dynamic-tags-function-list'
to find the proper tags.  It is up to each of those individual
functions to do caching and flushing if appropriate."
  (save-excursion
    ;; If a file is in memory, switch to that buffer.  This allows
    ;; us to use the local variable.  If the file is on disk, we
    ;; can try a few of the defaults that can get tags without
    ;; opening the file.
    (if (get-file-buffer file)
	(set-buffer (get-file-buffer file)))
    ;; If there is a buffer-local value of
    ;; speedbar-dynamic-tags-function-list, it will now be available.
    (let ((dtf speedbar-dynamic-tags-function-list)
	  (ret t))
      (while (and (eq ret t) dtf)
	(setq ret
	      (if (fboundp (car (car dtf)))
		  (funcall (car (car dtf)) file)
		t))
	(if (eq ret t)
	    (setq dtf (cdr dtf))))
      (if (eq ret t)
	  ;; No valid tag list, return nil
	  nil
	;; We have some tags.  Return the list with the insert fn
	;; prepended
	(cons (cdr (car dtf)) ret)))))