summaryrefslogtreecommitdiff
path: root/queries
diff options
context:
space:
mode:
Diffstat (limited to 'queries')
-rw-r--r--queries/swift/highlights.scm18
1 files changed, 17 insertions, 1 deletions
diff --git a/queries/swift/highlights.scm b/queries/swift/highlights.scm
index 3ce25f0a..95f38f9e 100644
--- a/queries/swift/highlights.scm
+++ b/queries/swift/highlights.scm
@@ -29,7 +29,15 @@
(inheritance_constraint (identifier (simple_identifier) @parameter))
(equality_constraint (identifier (simple_identifier) @parameter))
-["typealias" "struct" "class" "enum" "protocol" "extension"] @keyword
+[
+ "typealias"
+ "struct"
+ "class"
+ "enum"
+ "protocol"
+ "extension"
+ "indirect"
+] @keyword
(class_body (property_declaration (value_binding_pattern (non_binding_pattern (simple_identifier) @property))))
(protocol_property_declaration (value_binding_pattern (non_binding_pattern (simple_identifier) @property)))
@@ -69,6 +77,8 @@
(switch_entry ["fallthrough" @keyword])
(switch_entry (default_keyword) @keyword)
"return" @keyword.return
+(ternary_expression
+ ["?" ":"] @conditional)
["do" (throw_keyword) (catch_keyword)] @keyword
@@ -129,6 +139,12 @@
"%="
"!="
"!=="
+ "=="
"==="
+ "??"
+
"->"
+
+ "..<"
+ "..."
] @operator