diff options
| author | Dmitry Gutov | 2012-11-12 05:11:06 +0400 |
|---|---|---|
| committer | Dmitry Gutov | 2012-11-12 05:11:06 +0400 |
| commit | d1e1e53dec51a9cb8aa9d6033d32428051ab7e85 (patch) | |
| tree | 2acc4eaad376323cae41de08dcb66196858ce658 /lisp/progmodes/ruby-mode.el | |
| parent | a1d3e07e2896faadfd56b35a8c5f775353f39058 (diff) | |
| download | emacs-d1e1e53dec51a9cb8aa9d6033d32428051ab7e85.tar.gz emacs-d1e1e53dec51a9cb8aa9d6033d32428051ab7e85.zip | |
* lisp/progmodes/ruby-mode.el (ruby-move-to-block): When moving
backward, always stop at indentation. Reverts the change from
2012-08-12T22:06:56Z!monnier@iro.umontreal.ca.
Fixes: debbugs:12851
Diffstat (limited to 'lisp/progmodes/ruby-mode.el')
| -rw-r--r-- | lisp/progmodes/ruby-mode.el | 12 |
1 files changed, 1 insertions, 11 deletions
diff --git a/lisp/progmodes/ruby-mode.el b/lisp/progmodes/ruby-mode.el index 84cf7308d75..e4bfffa73c1 100644 --- a/lisp/progmodes/ruby-mode.el +++ b/lisp/progmodes/ruby-mode.el | |||
| @@ -898,17 +898,7 @@ or blocks containing the current block." | |||
| 898 | (back-to-indentation) | 898 | (back-to-indentation) |
| 899 | (if (looking-at (concat "\\<\\(" ruby-block-mid-re "\\)\\>")) | 899 | (if (looking-at (concat "\\<\\(" ruby-block-mid-re "\\)\\>")) |
| 900 | (setq done nil))))) | 900 | (setq done nil))))) |
| 901 | (back-to-indentation) | 901 | (back-to-indentation))) |
| 902 | (when (< n 0) | ||
| 903 | (let ((eol (point-at-eol)) state next) | ||
| 904 | (if (< orig eol) (setq eol orig)) | ||
| 905 | (setq orig (point)) | ||
| 906 | (while (and (setq next (apply 'ruby-parse-partial eol state)) | ||
| 907 | (< (point) eol)) | ||
| 908 | (setq state next)) | ||
| 909 | (when (cdaadr state) | ||
| 910 | (goto-char (cdaadr state))) | ||
| 911 | (backward-word))))) | ||
| 912 | 902 | ||
| 913 | (defun ruby-beginning-of-block (&optional arg) | 903 | (defun ruby-beginning-of-block (&optional arg) |
| 914 | "Move backward to the beginning of the current block. | 904 | "Move backward to the beginning of the current block. |