diff options
| author | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2002-07-30 10:54:33 +0000 |
|---|---|---|
| committer | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2002-07-30 10:54:33 +0000 |
| commit | 45f1eb4d305ab3c48f059139429b7b1337be8779 (patch) | |
| tree | 343f73aacbbb9c0e0babda3428434927692c5c7e /misc | |
| parent | 8f257d95cbd4fdd8466f665c2e596220907a030f (diff) | |
| download | ruby-45f1eb4d305ab3c48f059139429b7b1337be8779.tar.gz ruby-45f1eb4d305ab3c48f059139429b7b1337be8779.tar.xz ruby-45f1eb4d305ab3c48f059139429b7b1337be8779.zip | |
* misc/ruby-mode.el (ruby-accurate-end-of-block): restrict search
region.
* misc/ruby-mode.el (ruby-parse-partial): reversed wrong patch.
git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@2671 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'misc')
| -rw-r--r-- | misc/ruby-mode.el | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/misc/ruby-mode.el b/misc/ruby-mode.el index 7bc5ec072..139bebceb 100644 --- a/misc/ruby-mode.el +++ b/misc/ruby-mode.el @@ -173,8 +173,9 @@ Also ignores spaces after parenthesis when 'space.") (defun ruby-accurate-end-of-block (&optional end) (let (state) + (or end (setq end (point-max))) (while (and (setq state (apply 'ruby-parse-partial end state)) - (>= (nth 2 state) 0))))) + (>= (nth 2 state) 0) (< (point) end))))) (defun ruby-mode-variables () (set-syntax-table ruby-mode-syntax-table) @@ -483,8 +484,8 @@ The variable ruby-indent-level controls the amount of indentation. (t (error (format "bad string %s" (buffer-substring (point) pnt) - ))))) - (list in-string nest depth pcol))) + )))))) + (list in-string nest depth pcol)) (defun ruby-parse-region (start end) (let (state) |
