[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] scratch/flymake-refactor e7e9d4f 1/7: Fix flymake-backends
From: |
João Távora |
Subject: |
[Emacs-diffs] scratch/flymake-refactor e7e9d4f 1/7: Fix flymake-backends defcustom's docstring and usage |
Date: |
Wed, 23 Aug 2017 19:52:57 -0400 (EDT) |
branch: scratch/flymake-refactor
commit e7e9d4f52e2d993ce7c6e90a1d7834aaef55c9f0
Author: João Távora <address@hidden>
Commit: João Távora <address@hidden>
Fix flymake-backends defcustom's docstring and usage
* lisp/progmodes/flymake-ui.el (flymake-backends): Fix docstring.
(flymake-proc-can-syntax-check-buffer): Simplify implementation.
---
lisp/progmodes/flymake-ui.el | 23 ++++++++++-------------
1 file changed, 10 insertions(+), 13 deletions(-)
diff --git a/lisp/progmodes/flymake-ui.el b/lisp/progmodes/flymake-ui.el
index 3fb1eca..dd09b88 100644
--- a/lisp/progmodes/flymake-ui.el
+++ b/lisp/progmodes/flymake-ui.el
@@ -111,13 +111,12 @@ See `flymake-error-bitmap' and `flymake-warning-bitmap'."
(defcustom flymake-backends '()
"Ordered list of backends providing syntax check information for a buffer.
Value is an alist of conses (PREDICATE . CHECKER). Both PREDICATE
-and CHECKER are functions called with a single argument, the
-buffer in which `flymake-mode' was enabled. PREDICATE is expected
-to (quickly) return t or nil if the buffer can be syntax checked
-by CHECKER, which in can performs more morose operations,
-possibly asynchronously."
- :group 'flymake
- :type 'alist)
+and CHECKER are functions called without arguments and within the
+the buffer in which `flymake-mode' was enabled. PREDICATE is
+expected to (quickly) return t or nil if the buffer can be
+syntax-checked by CHECKER, in which case it can then perform
+more morose operations, possibly asynchronously." :group
+'flymake :type 'alist)
(defvar-local flymake-timer nil
"Timer for starting syntax check.")
@@ -457,12 +456,10 @@ For the format of LINE-ERR-INFO, see
`flymake-ler-make-ler'."
"The currently active backend selected by `flymake-mode'")
(defun flymake--can-syntax-check-buffer (buffer)
- (let ((all flymake-backends)
- (candidate))
- (catch 'done
- (while (setq candidate (pop all))
- (when (with-current-buffer buffer (funcall (car candidate)))
- (throw 'done (cdr candidate)))))))
+ (catch 'done
+ (dolist (candidate flymake-backends)
+ (when (with-current-buffer buffer (funcall (car candidate)))
+ (throw 'done (cdr candidate))))))
(defun flymake--start-syntax-check ()
(funcall flymake--backend))
- [Emacs-diffs] branch scratch/flymake-refactor created (now fea31e2), João Távora, 2017/08/23
- [Emacs-diffs] scratch/flymake-refactor e7e9d4f 1/7: Fix flymake-backends defcustom's docstring and usage,
João Távora <=
- [Emacs-diffs] scratch/flymake-refactor b30fb9c 3/7: Allow running flymake-tests.el from interactive sessions, João Távora, 2017/08/23
- [Emacs-diffs] scratch/flymake-refactor dc39d65 4/7: flymake-ui.el provides new flymake-report as a re-entry point for backends., João Távora, 2017/08/23
- [Emacs-diffs] scratch/flymake-refactor 3b06b52 2/7: Adjust flymake's UI/backend split started in earlier commit, João Távora, 2017/08/23
- [Emacs-diffs] scratch/flymake-refactor 740572e 5/7: Completely rewrite flymake's subprocess output processing, João Távora, 2017/08/23
- [Emacs-diffs] scratch/flymake-refactor fea31e2 7/7: Rename many flymake-proc.el symbols with internal "--" prefixes, João Távora, 2017/08/23
- [Emacs-diffs] scratch/flymake-refactor 6bf3a42 6/7: Move symbols in flymake-proc.el to separate namespace, João Távora, 2017/08/23