PATCH: match regexps after common Kernel methods

Doug Kearns djkea2 at mugca.its.monash.edu.au
Fri Sep 26 01:39:32 EDT 2003


This allows regexps to match after some common Kernel methods such as
scan, split, (g)sub.

Regards,
Doug


Index: syntax/ruby.vim
===================================================================
RCS file: /var/cvs/vim-ruby/vim-ruby/syntax/ruby.vim,v
retrieving revision 1.26
diff -u -r1.26 ruby.vim
--- syntax/ruby.vim	21 Sep 2003 14:07:56 -0000	1.26
+++ syntax/ruby.vim	21 Sep 2003 14:22:29 -0000
@@ -72,6 +72,7 @@
 
 " Normal Regular Expression
 syn region rubyString matchgroup=rubyStringDelimiter start="^\s*/" start="\<and\s*/"lc=3 start="\<or\s*/"lc=2 start="\<while\s*/"lc=5 start="\<until\s*/"lc=5 start="\<unless\s*/"lc=6 start="\<if\s*/"lc=2 start="\<elsif\s*/"lc=5 start="\<when\s*/"lc=4 start="\<not\s*/"lc=3  start="\<then\s*/"lc=4 start="[\~=!|&(,[]\s*/"lc=1 end="/[iomx]*" skip="\\\\\|\\/" contains=@rubyStringSpecial
+syn region rubyString matchgroup=rubyStringDelimiter start="\<split\s*/"lc=5 start="\<\%(scan\|gsub\)\s*/"lc=4 start="\<sub\s*/"lc=3 end="/[iomx]*" skip="\\\\\|\\/" contains=@rubyStringSpecial
 
 " Normal String and Shell Command Output
 syn region rubyString matchgroup=rubyStringDelimiter start="\"" end="\"" skip="\\\\\|\\\"" contains=@rubyStringSpecial


More information about the vim-ruby-devel mailing list