aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lisp/progmodes/ruby-mode.el7
1 files changed, 4 insertions, 3 deletions
diff --git a/lisp/progmodes/ruby-mode.el b/lisp/progmodes/ruby-mode.el
index 4ac289d529f..9a557484b58 100644
--- a/lisp/progmodes/ruby-mode.el
+++ b/lisp/progmodes/ruby-mode.el
@@ -1375,9 +1375,10 @@ With ARG, move backward multiple defuns. Negative ARG means
1375move forward." 1375move forward."
1376 (interactive "p") 1376 (interactive "p")
1377 (let (case-fold-search) 1377 (let (case-fold-search)
1378 (and (re-search-backward (concat "^\\s *" ruby-defun-beg-re "\\_>") 1378 (when (re-search-backward (concat "^\\s *" ruby-defun-beg-re "\\_>")
1379 nil t (or arg 1)) 1379 nil t (or arg 1))
1380 (beginning-of-line)))) 1380 (beginning-of-line)
1381 t)))
1381 1382
1382(defun ruby-end-of-defun () 1383(defun ruby-end-of-defun ()
1383 "Move point to the end of the current defun. 1384 "Move point to the end of the current defun.