pboettch / vim-cmake-syntax

Vim syntax highlighting rules for modern CMake.
Other
96 stars 32 forks source link

Fix spell checking inside CMake functions #20

Closed vadz closed 1 year ago

vadz commented 4 years ago

cmakeArguments syntax region used "contains=ALLBUT" which, in particular, made it contain "@Spell", i.e. told the spell checked to check everything inside the function arguments. This was undesirable, as can be seen with the following simple example

cmake_minimum_required(VERSION 3.1)

# This should be spel-checked.
set(this_should_not_be_spel_checked "some value")

in which "spell" misspelling was highlighted in both places and not just in the first one.

Fix this by explicitly excluding @Spell from cmakeArguments and, to compensate for the text inside the string used in the arguments not being spell-checked any more, add it to cmakeString explicitly.

pboettch commented 4 years ago

Thanks, will be integrated as soon as possible.