[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Working Around for cl-count

From: Eric James Michael Ritz
Subject: Working Around for cl-count
Date: Thu, 29 Nov 2012 11:06:48 -0500
User-agent: Mozilla/5.0 (X11; Linux i686; rv:17.0) Gecko/17.0 Thunderbird/17.0

(My apologies if this is a repost. It has been a hectic morning.)

Hello my fellow Elisp hackers,

I am maintaining a php-mode for those Emacs users writin PHP software. Recently improvide formatting for anonymous functions when used as arguments to functions. The code for the formatting look is thus:

(defun php-unindent-closure ()
  (let ((syntax (mapcar 'car c-syntactic-context)))
    (if (and (member 'arglist-cont-nonempty syntax)
              (member 'statement-block-intro syntax)
              (member 'brace-list-intro syntax)
              (member 'brace-list-close syntax)
              (member 'block-close syntax)))
          (delete-char (* (cl-count 'arglist-cont-nonempty syntax)

Versions of Emacs less than version 24.2 complain about the lack of cl-count. Does anyone have suggestions about a good way to handle the non-existence of cl-count in previous version?

Thank you in advanced for the help.

-- ejmr 南無妙法蓮華經

reply via email to

[Prev in Thread] Current Thread [Next in Thread]