From 55b2a6df6892f3b6080419ee0e3ea305eccc1dcc Mon Sep 17 00:00:00 2001 From: Henrik Lissner Date: Mon, 5 Mar 2018 02:59:21 -0500 Subject: [PATCH] Fix doom/forward-to-last-non-comment-or-eol when visual-line-mode is off #450 --- core/autoload/editor.el | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/core/autoload/editor.el b/core/autoload/editor.el index 57048a0db..54c7e9fae 100644 --- a/core/autoload/editor.el +++ b/core/autoload/editor.el @@ -51,7 +51,10 @@ beginning of the line. The opposite of "Jumps between the last non-blank, non-comment character in the line and the true end of the line. The opposite of `doom/backward-to-bol-or-indent'." (interactive) - (let ((eol (save-excursion (end-of-visual-line) (point)))) + (let ((eol (save-excursion (if visual-line-mode + (end-of-visual-line) + (end-of-line)) + (point)))) (if (and (sp-point-in-comment) (not (= (point) eol))) (goto-char eol) (let* ((bol (save-excursion (beginning-of-visual-line) (point)))