helpful

a fork of Wilfred's helpful
git clone https://git.trogloxene.org/helpful.git
Log | Files | Refs | README

commit 3aa08da7a151f1928bf0e3d12fc2443b6485b6ef
parent db1e15b3783c83d9781a546f37b900ad53576659
Author: Wilfred Hughes <me@wilfred.me.uk>
Date:   Sun, 25 Sep 2022 15:06:36 -0700

Ignore comments when narrowing to defun

Closes #287

Diffstat:
Mhelpful.el | 3++-
1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/helpful.el b/helpful.el @@ -1248,7 +1248,8 @@ If the source code cannot be found, return the sexp used." (forward-char) (narrow-to-region pos (point))) ;; Narrow to the top-level definition. - (narrow-to-defun t)) + (let ((parse-sexp-ignore-comments t)) + (narrow-to-defun t))) ;; If there was a preceding comment, POS will be ;; after that comment. Move the position to include that comment.