Function: follow-cache-valid-p

follow-cache-valid-p is a byte-compiled function defined in follow.el.gz.

Signature

(follow-cache-valid-p WINDOWS)

Documentation

Test if the cached value of follow-windows-start-end can be used.

Note that this handles the case when the cache has been set to nil.

Source Code

;; Defined in /usr/src/emacs/lisp/follow.el.gz
;; The result from `follow-windows-start-end' is cached when using
;; a handful simple commands, like cursor movement commands.

(defsubst follow-cache-valid-p (windows)
  "Test if the cached value of `follow-windows-start-end' can be used.
Note that this handles the case when the cache has been set to nil."
  (let ((res t)
	(cache follow-windows-start-end-cache))
    (while (and res windows cache)
      (setq res (and (eq (car windows)
			 (car (car cache)))
		     (eq (window-start (car windows))
			 (car (cdr (car cache))))))
      (setq windows (cdr windows))
      (setq cache (cdr cache)))
    (and res (null windows) (null cache))))