summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--paredit.el4
1 files changed, 3 insertions, 1 deletions
diff --git a/paredit.el b/paredit.el
index 5c27bab..2e2fb28 100644
--- a/paredit.el
+++ b/paredit.el
@@ -757,7 +757,9 @@ If such a comment exists, delete the comment (including all leading
(count 0))
(catch 'exit
(while (< count magnitude)
- (let ((p (scan-sexps (point) direction)))
+ (let ((p
+ (paredit-handle-sexp-errors (scan-sexps (point) direction)
+ nil)))
(if (not p) (throw 'exit nil))
(goto-char p))
(setq count (+ count 1)))))