From e31bba5d97bfbc59d94a47f40e7ad9e36a5a53ee Mon Sep 17 00:00:00 2001 From: Uy Ha Date: Fri, 10 Sep 2021 15:19:10 +0200 Subject: [cmake] add highlights for `if` command constant --- queries/cmake/highlights.scm | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/queries/cmake/highlights.scm b/queries/cmake/highlights.scm index 9be78c1b0..cecf2f842 100644 --- a/queries/cmake/highlights.scm +++ b/queries/cmake/highlights.scm @@ -64,3 +64,15 @@ (#match? @function.builtin "\\c^(set)$") ) +(if_command + (if) + (argument) @keyword.operator + (#any-of? @keyword.operator "NOT" "AND" "OR" + "COMMAND" "POLICY" "TARGET" "TEST" "DEFINED" "IN_LIST" + "EXISTS" "IS_NEWER_THAN" "IS_DIRECTORY" "IS_SYMLINK" "IS_ABSOLUTE" + "MATCHES" + "LESS" "GREATER" "EQUAL" "LESS_EQUAL" "GREATER_EQUAL" + "STRLESS" "STRGREATER" "STREQUAL" "STRLESS_EQUAL" "STRGREATER_EQUAL" + "VERSION_LESS" "VERSION_GREATER" "VERSION_EQUAL" "VERSION_LESS_EQUAL" "VERSION_GREATER_EQUAL" + ) +) -- cgit v1.2.3-70-g09d2