Auxiliary: Broken VIM syntax highlighting for comment, bracket argument and bracket comment
Auxiliary/vim/syntax/cmake.vim
incorrectly defines cmakeBracketArguement, cmakeComment and cmakeBracketArgument as
syn region cmakeBracketArgument start="\[\z(=\?\|=[0-9]*\)\[" end="\]\z1\]" contains=cmakeTodo,@Spell
syn region cmakeComment start="#" end="$" contains=cmakeTodo,@Spell
syn region cmakeBracketComment start="\[\z(=*\)\[" end="\]\z1\]" contains=cmakeTodo,@Spell
cmakeBracketArgument
doesn't match valid bracket argument containing more than one =
in opening bracket, e.g., [==[...]==]
, and mismatches invalid text such as [=0123[...]=0123]
.
cmakeBracketComment
should start with #
.
cmakeComment
mismatches and overrides bracket comment.
The correct syntaxs should look like
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
Edited by Namniav W