[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] emacs-26 8c85ab0 12/39: Echo Flymake error messages when n
From: |
João Távora |
Subject: |
[Emacs-diffs] emacs-26 8c85ab0 12/39: Echo Flymake error messages when navigating errors interactively |
Date: |
Tue, 3 Oct 2017 10:04:49 -0400 (EDT) |
branch: emacs-26
commit 8c85ab027eefb352a39d68433f64bfaa1c446856
Author: João Távora <address@hidden>
Commit: João Távora <address@hidden>
Echo Flymake error messages when navigating errors interactively
Perhaps binding M-n and M-p to flymake-goto-next-error and
flymake-goto-prev-error also wouldn't be a bad idea.
* lisp/progmodes/flymake.el (flymake-goto-next-error): Use
target overlay's help-echo.
---
lisp/progmodes/flymake.el | 22 +++++++++++++---------
1 file changed, 13 insertions(+), 9 deletions(-)
diff --git a/lisp/progmodes/flymake.el b/lisp/progmodes/flymake.el
index e8d5de6..f9aa098 100644
--- a/lisp/progmodes/flymake.el
+++ b/lisp/progmodes/flymake.el
@@ -557,15 +557,19 @@ return DEFAULT."
(chain (cl-member-if (lambda (ov)
(if (cl-plusp n)
(> (overlay-start ov)
- (point))
- (< (overlay-start ov)
- (point))))
- ovs))
- (target (nth (1- n) chain)))
- (if target
- (goto-char (overlay-start target))
- (when interactive
- (user-error "No more flymake errors")))))
+ (point))
+ (< (overlay-start ov)
+ (point))))
+ ovs))
+ (target (nth (1- n) chain)))
+ (cond (target
+ (goto-char (overlay-start target))
+ (when interactive
+ (message
+ (funcall (overlay-get target 'help-echo)
+ nil nil (point)))))
+ (interactive
+ (user-error "No more flymake errors")))))
(defun flymake-goto-prev-error (&optional n interactive)
"Go to previous, or Nth previous, flymake error in buffer."
- [Emacs-diffs] emacs-26 updated (0fff900 -> ca08b69), João Távora, 2017/10/03
- [Emacs-diffs] emacs-26 bbcb079 06/39: Allow running Flymake tests from interactive sessions, João Távora, 2017/10/03
- [Emacs-diffs] emacs-26 1c30f9f 05/39: Flymake diagnostics now apply to arbitrary buffer regions, João Távora, 2017/10/03
- [Emacs-diffs] emacs-26 8c85ab0 12/39: Echo Flymake error messages when navigating errors interactively,
João Távora <=
- [Emacs-diffs] emacs-26 0d26e45 11/39: Add a new Flymake test for multiple errors and warnings, João Távora, 2017/10/03
- [Emacs-diffs] emacs-26 54beebb 14/39: Flymake highlights GCC info/notes as detected by flymake-proc.el, João Távora, 2017/10/03
- [Emacs-diffs] emacs-26 f1601be 02/39: Flymake provides flymake-report re-entry point for backends, João Távora, 2017/10/03
- [Emacs-diffs] emacs-26 ae64bf1 08/39: New Flymake variable flymake-diagnostic-types-alist and much cleanup, João Távora, 2017/10/03
- [Emacs-diffs] emacs-26 6954270 03/39: Completely rewrite Flymake's subprocess output processing, João Távora, 2017/10/03
- [Emacs-diffs] emacs-26 f930963 18/39: Simplify Flymake logging and erroring, João Távora, 2017/10/03
- [Emacs-diffs] emacs-26 734aa88 09/39: Flymake's flymake-proc.el parses column numbers from gcc/javac errors, João Távora, 2017/10/03
- [Emacs-diffs] emacs-26 9f8ad13 07/39: Refactor Flymake tests in preparation for more tests, João Távora, 2017/10/03
- [Emacs-diffs] emacs-26 491cc4a 13/39: Flymake checks file names before considering diagnostics, João Távora, 2017/10/03
- [Emacs-diffs] emacs-26 7787988 10/39: Flymake warning face easier to distinguish, João Távora, 2017/10/03