summaryrefslogtreecommitdiff
path: root/misc
diff options
context:
space:
mode:
authormatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2004-02-13 16:03:15 +0000
committermatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2004-02-13 16:03:15 +0000
commit829a44822d5e3fd4457f44c401d82eb14c52c8e9 (patch)
tree769c0b1007ca976ec66e03576e4abf78dcda287f /misc
parentbe1de4f8db9626be0341d588b6b36aaae06a52d2 (diff)
* re.c (KR_REHASH): wrong hash value on sizeof(long) > sizeof(int).
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@5693 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'misc')
-rw-r--r--misc/ruby-mode.el10
1 files changed, 6 insertions, 4 deletions
diff --git a/misc/ruby-mode.el b/misc/ruby-mode.el
index 106668de19..f1762e6b5d 100644
--- a/misc/ruby-mode.el
+++ b/misc/ruby-mode.el
@@ -222,7 +222,7 @@ Also ignores spaces after parenthesis when 'space."
(make-variable-buffer-local 'comment-column)
(setq comment-column ruby-comment-column)
(make-variable-buffer-local 'comment-start-skip)
- (setq comment-start-skip "\\(^\\|\\s-\\);?#+ *")
+ (setq comment-start-skip "#+ *")
(setq indent-tabs-mode ruby-indent-tabs-mode)
(make-local-variable 'parse-sexp-ignore-comments)
(setq parse-sexp-ignore-comments t)
@@ -731,8 +731,10 @@ The variable ruby-indent-level controls the amount of indentation.
(not (looking-at ruby-block-hanging-re))
(eq (ruby-deep-indent-paren-p t) 'space)
(not (bobp)))
- (ruby-beginning-of-arg (or begin parse-start) (point))
- (current-column))
+ (save-excursion
+ (widen)
+ (ruby-beginning-of-arg (or begin parse-start) (point))
+ (current-column)))
(t
(+ indent ruby-indent-level))))))))
indent)))
@@ -802,7 +804,7 @@ An end of a defun is found by moving forward from the beginning of one."
((> start pos)
(setq done t)))))
(if done
- (progn
+ (save-excursion
(back-to-indentation)
(if (looking-at ruby-block-mid-re)
(setq done nil))))))