From 167d14181ce4d1f1cca6cb6d0e7b26f80ab7de65 Mon Sep 17 00:00:00 2001 From: Eli Zaretskii Date: Wed, 19 Feb 1997 15:48:50 +0000 Subject: [PATCH] (compile-mouse-goto-error): Move to end of line before calling `compile-reinitialize-errors', so that it always sees the entire filename. --- lisp/progmodes/compile.el | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/lisp/progmodes/compile.el b/lisp/progmodes/compile.el index a95d260daa6..77608903b22 100644 --- a/lisp/progmodes/compile.el +++ b/lisp/progmodes/compile.el @@ -897,6 +897,11 @@ Does NOT find the source line like \\[next-error]." (or (compilation-buffer-p (current-buffer)) (error "Not in a compilation buffer.")) (setq compilation-last-buffer (current-buffer)) + ;; `compile-reinitialize-errors' needs to see the complete filename + ;; on the line where they clicked the mouse. Since it only looks + ;; upto point, moving point to eol makes sure the filename is + ;; visible to `compile-reinitialize-errors'. + (end-of-line) (compile-reinitialize-errors nil (point)) ;; Move to bol; the marker for the error on this line will point there. -- 2.39.5