summaryrefslogtreecommitdiffstats
path: root/Auxiliary
diff options
context:
space:
mode:
authornamniav <namniav@gmail.com>2023-12-09 20:17:11 (GMT)
committerBrad King <brad.king@kitware.com>2023-12-11 15:10:44 (GMT)
commit56fb01a176891fab1152502c0c49a8b7b52f8b29 (patch)
treebe90503c3f95ec2f484bf1a1b200bb791f8d3749 /Auxiliary
parent2040b79a39a6d1ea3a60e9aba24907af54599134 (diff)
downloadCMake-56fb01a176891fab1152502c0c49a8b7b52f8b29.zip
CMake-56fb01a176891fab1152502c0c49a8b7b52f8b29.tar.gz
CMake-56fb01a176891fab1152502c0c49a8b7b52f8b29.tar.bz2
vim: Fix syntax highlighting for bracket arguments and comments
Fix VIM syntax highlighting for `cmakeBracketArgument`, `cmakeComment` and `cmakeBracketComment`. Fixes: #25488
Diffstat (limited to 'Auxiliary')
-rw-r--r--Auxiliary/vim/syntax/cmake.vim6
1 files changed, 3 insertions, 3 deletions
diff --git a/Auxiliary/vim/syntax/cmake.vim b/Auxiliary/vim/syntax/cmake.vim
index aa9ebe4..c95503b 100644
--- a/Auxiliary/vim/syntax/cmake.vim
+++ b/Auxiliary/vim/syntax/cmake.vim
@@ -19,10 +19,10 @@ endif
let s:keepcpo= &cpo
set cpo&vim
-syn region cmakeBracketArgument start="\[\z(=\?\|=[0-9]*\)\[" end="\]\z1\]" contains=cmakeTodo,@Spell
+syn region cmakeBracketArgument start="\[\z(=*\)\[" end="\]\z1\]" contains=cmakeTodo,@Spell
-syn region cmakeComment start="#" end="$" contains=cmakeTodo,@Spell
-syn region cmakeBracketComment start="\[\z(=*\)\[" end="\]\z1\]" contains=cmakeTodo,@Spell
+syn region cmakeComment start="#\(\[=*\[\)\@!" end="$" contains=cmakeTodo,@Spell
+syn region cmakeBracketComment start="#\[\z(=*\)\[" end="\]\z1\]" contains=cmakeTodo,@Spell
syn match cmakeEscaped /\(\\\\\|\\"\|\\n\|\\t\)/ contained
syn region cmakeRegistry start="\[" end="]" contained oneline contains=cmakeTodo,cmakeEscaped