From 71bb1da621a48856c7f8ca10e674f2ac8c0a9005 Mon Sep 17 00:00:00 2001 From: Hoang Nguyen Date: Thu, 8 Jun 2023 14:13:26 +0000 Subject: [PATCH] feat(jsonnet): add "for" & "function", update operator highlights `expr` -> `operator` doesn't exist in the node tree anymore after https://github.com/sourcegraph/tree-sitter-jsonnet/commit/505f5bd90053ae895aa3d6f2bac8071dd9abd8b2 --- queries/jsonnet/highlights.scm | 24 ++++++++++++++++++++++-- 1 file changed, 22 insertions(+), 2 deletions(-) diff --git a/queries/jsonnet/highlights.scm b/queries/jsonnet/highlights.scm index eb8d22be9..4267c988f 100644 --- a/queries/jsonnet/highlights.scm +++ b/queries/jsonnet/highlights.scm @@ -30,13 +30,33 @@ ":::" ] @punctuation.delimiter -(expr - operator: (_) @operator) +(unaryop) @operator [ "+" + "-" + "*" + "/" + "%" + "^" + "==" + "!=" + "<=" + ">=" + "<" + ">" "=" + "&" + "|" + "<<" + ">>" + "&&" + "||" ] @operator +"for" @repeat + +"function" @keyword.function + "in" @keyword.operator [