summaryrefslogtreecommitdiffstats
path: root/misc
diff options
context:
space:
mode:
authormatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2000-07-04 04:17:26 +0000
committermatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2000-07-04 04:17:26 +0000
commitf0367359d6f55de6caf62fd1dbb72d3661d4ae12 (patch)
tree3ab2686a359f6cbdda8446d7382f9aa541c2490a /misc
parent6820886b9beea4608e3c4f135406648c53129124 (diff)
downloadruby-f0367359d6f55de6caf62fd1dbb72d3661d4ae12.tar.gz
ruby-f0367359d6f55de6caf62fd1dbb72d3661d4ae12.tar.xz
ruby-f0367359d6f55de6caf62fd1dbb72d3661d4ae12.zip
matz
git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@810 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'misc')
-rw-r--r--misc/ruby-mode.el15
1 files changed, 9 insertions, 6 deletions
diff --git a/misc/ruby-mode.el b/misc/ruby-mode.el
index 763c076d8..cffd853bb 100644
--- a/misc/ruby-mode.el
+++ b/misc/ruby-mode.el
@@ -547,12 +547,15 @@ The variable ruby-indent-level controls the amount of indentation.
(setq bol (point))
(end-of-line)
(skip-chars-backward " \t")
- (and (re-search-backward "#" (save-excursion
- (beginning-of-line)
- (point)) t)
- (setq state (ruby-parse-region parse-start (point)))
- (nth 0 state)
- (goto-char (nth 0 state)))
+ (let ((pos (point)))
+ (and
+ (re-search-backward "#" (save-excursion
+ (beginning-of-line)
+ (point)) t)
+ (skip-chars-backward " \t")
+ (setq state (ruby-parse-region parse-start (point)))
+ (nth 0 state)
+ (goto-char pos)))
(or (bobp) (forward-char -1))
(and
(or (and (looking-at ruby-symbol-re)