From bbe69b4022b577a801653991a8b7f7f2ab869e97 Mon Sep 17 00:00:00 2001 From: zeertzjq Date: Wed, 12 Jun 2024 10:23:09 +0800 Subject: vim-patch:959c3c8: runtime(vim): Update base-syntax, configurable comment string highlighting (vim/vim#14931) Allow highlighting of strings within comments to be disabled by setting g:vimsyn_comment_strings to false. https://github.com/vim/vim/commit/959c3c887b2e52c7141b2a09a53634481911b1b7 Co-authored-by: dkearns --- runtime/syntax/vim.vim | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'runtime/syntax') diff --git a/runtime/syntax/vim.vim b/runtime/syntax/vim.vim index d916a666c9..d16d62dc4a 100644 --- a/runtime/syntax/vim.vim +++ b/runtime/syntax/vim.vim @@ -359,7 +359,9 @@ syn region vimUserCmdBlock contained matchgroup=vimSep start="{" end="}" contain " Lower Priority Comments: after some vim commands... {{{2 " ======================= -syn region vimCommentString contained oneline start='\S\s\+"'ms=e end='"' +if get(g:, "vimsyn_comment_strings", 1) + syn region vimCommentString contained oneline start='\S\s\+"'ms=e end='"' +endif if s:vim9script syn match vimComment excludenl +\s"[^\-:.%#=*].*$+lc=1 contains=@vimCommentGroup,vimCommentString contained -- cgit