From 87a26c5bf169bafbee837e2323f24cfb07e35250 Mon Sep 17 00:00:00 2001 From: Adam Stankiewicz Date: Tue, 21 Dec 2021 14:41:23 +0100 Subject: Update --- syntax/ruby.vim | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'syntax/ruby.vim') diff --git a/syntax/ruby.vim b/syntax/ruby.vim index bbf86e8a..d5c9e728 100644 --- a/syntax/ruby.vim +++ b/syntax/ruby.vim @@ -367,6 +367,9 @@ if !exists("b:ruby_no_expensive") && !exists("ruby_no_expensive") SynFold 'class' syn region rubyClassBlock start="\" matchgroup=rubyClass skip="\" @@ -433,9 +436,10 @@ endif " Comments and Documentation {{{1 syn match rubySharpBang "\%^#!.*" display syn keyword rubyTodo FIXME NOTE TODO OPTIMIZE HACK REVIEW XXX todo contained -syn match rubyEncoding "[[:alnum:]-]\+" contained display +syn match rubyEncoding "[[:alnum:]-_]\+" contained display syn match rubyMagicComment "\c\%<3l#\s*\zs\%(coding\|encoding\):" contained nextgroup=rubyEncoding skipwhite syn match rubyMagicComment "\c\%<10l#\s*\zs\%(frozen_string_literal\|warn_indent\|warn_past_scope\):" contained nextgroup=rubyBoolean skipwhite +syn match rubyMagicComment "\c\%<10l#\s*\zs\%(shareable_constant_value\):" contained nextgroup=rubyEncoding skipwhite syn match rubyComment "#.*" contains=@rubyCommentSpecial,rubySpaceError,@Spell syn cluster rubyCommentSpecial contains=rubySharpBang,rubyTodo,rubyMagicComment -- cgit v1.2.3