From 3f91366caf89e4446836a3953162b8152cc6714e Mon Sep 17 00:00:00 2001 From: knu Date: Thu, 7 Aug 2008 09:04:27 +0000 Subject: * misc/ruby-mode.el (ruby-imenu-create-index-in-block): Fix the regexp to only pick definition lines properly. `module_funtion' is not a definition of a module named `_function'. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18413 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- misc/ruby-mode.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'misc') diff --git a/misc/ruby-mode.el b/misc/ruby-mode.el index 3c70a64967..1eeaa6575f 100644 --- a/misc/ruby-mode.el +++ b/misc/ruby-mode.el @@ -187,7 +187,7 @@ Also ignores spaces after parenthesis when 'space." (let ((index-alist '()) name next pos decl sing) (goto-char beg) - (while (re-search-forward "^\\s *\\(\\(class\\>\\(\\s *<<\\)?\\|module\\>\\)\\s *\\([^\(<\n ]+\\)\\|\\(def\\|alias\\)\\>\\s *\\([^\(\n ]+\\)\\)" end t) + (while (re-search-forward "^\\s *\\(\\(class\\s +\\|\\(class\\s *<<\\s *\\)\\|module\\s +\\)\\([^\(<\n ]+\\)\\|\\(def\\|alias\\)\\s +\\([^\(\n ]+\\)\\)" end t) (setq sing (match-beginning 3)) (setq decl (match-string 5)) (setq next (match-end 0)) -- cgit v1.2.3