Function: idlwave-shorten-syntax

idlwave-shorten-syntax is a byte-compiled function defined in idlwave.el.gz.

Signature

(idlwave-shorten-syntax SYNTAX NAME &optional CLASS)

Source Code

;; Defined in /usr/src/emacs/lisp/obsolete/idlwave.el.gz
(defun idlwave-shorten-syntax (syntax name &optional class)
  ;; From a list of syntax statements, shorten with %s and group with "or"
  (let ((case-fold-search t))
    (mapconcat
     (lambda (x)
       (while (string-match name x)
	 (setq x (replace-match "%s" t t x)))
       (if class
	   (while (string-match class x)
	     (setq x (replace-match "%s" t t x))))
       x)
     (nreverse syntax)
     " or ")))