Function: TeX-keep-hooks-in-dialect

TeX-keep-hooks-in-dialect is a byte-compiled function defined in tex.el.

Signature

(TeX-keep-hooks-in-dialect HOOKS DIALECT-LIST)

Documentation

Scan HOOKS for all hooks the associated dialect of which is found in DIALECT-LIST and return the list thereof.

Source Code

;; Defined in ~/.emacs.d/elpa/auctex-14.1.2/tex.el
(defun TeX-keep-hooks-in-dialect (hooks dialect-list)
  "Scan HOOKS for all hooks the associated dialect of which is
found in DIALECT-LIST and return the list thereof."
  (let (ret dialect-list-1)
    (dolist (hook hooks)
      (setq dialect-list-1 (and (vectorp hook) (eq (aref hook 0) 'TeX-style-hook)
                                (TeX-shdex-listify (aref hook 2))))
      (while dialect-list-1
        (when (memq (pop dialect-list-1) dialect-list)
          (push hook ret)
          (setq dialect-list-1 nil)))
    ret)))