Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Highlight unicode characters in constants

Except those which are the first letter (e.g. `Ír`), as Ruby does not
recognize them as valid constants. (See also #138)
  • Loading branch information...
commit ab7c7e4cc3c4ac235cebcb4b2495ebdd0d67fdc0 1 parent b60da6c
Andrew Marshall amarshall authored
Showing with 1 addition and 1 deletion.
  1. +1 −1  syntax/ruby.vim
2  syntax/ruby.vim
View
@@ -92,7 +92,7 @@ syn match rubyFloat "\%(\%(\w\|[]})\"']\s*\)\@<!-\)\=\<\%(0\|[1-9]\d*\%(_\d\+\)*
syn match rubyLocalVariableOrMethod "\<[_[:lower:]][_[:alnum:]]*[?!=]\=" contains=NONE display transparent
syn match rubyBlockArgument "&[_[:lower:]][_[:alnum:]]" contains=NONE display transparent
-syn match rubyConstant "\%(\%(^\|[^.]\)\.\_s*\)\@<!\<\u\w*\>\%(\s*(\)\@!"
+syn match rubyConstant "\%(\%(^\|[^.]\)\.\_s*\)\@<!\<\u\%(\w\|[^\x00-\x7F]\)*\>\%(\s*(\)\@!"
syn match rubyClassVariable "@@\%(\h\|[^\x00-\x7F]\)\%(\w\|[^\x00-\x7F]\)*" display
syn match rubyInstanceVariable "@\%(\h\|[^\x00-\x7F]\)\%(\w\|[^\x00-\x7F]\)*" display
syn match rubyGlobalVariable "$\%(\%(\h\|[^\x00-\x7F]\)\%(\w\|[^\x00-\x7F]\)*\|-.\)"
Please sign in to comment.
Something went wrong with that request. Please try again.