on master help sign in
Update Unison highlights (#8315)
7fa5f34zetashift
runtime/queries/unison/highlights.scm+21−6
@@ -10,14 +10,18 @@
10[
10[
11 (kw_forall)
11 (kw_forall)
12 (unique_kw)
12 (unique_kw)
13+ (structural_kw)
13 (type_kw)
14 (type_kw)
14 (kw_equals)
15 (kw_equals)
15 (do)
16 (do)
17+ (ability)
18+ (where)
16] @keyword
19] @keyword
17
20
18(kw_let) @keyword.function
21(kw_let) @keyword.function
19(type_kw) @keyword.storage.type
22(type_kw) @keyword.storage.type
20(unique) @keyword.storage.modifier
23(unique) @keyword.storage.modifier
24+(structural) @keyword.storage.modifier
21("use") @keyword.control.import
25("use") @keyword.control.import
22
26
23
27
@@ -31,6 +35,7 @@
31 (arrow_symbol)
35 (arrow_symbol)
32 (">")
36 (">")
33 (or)
37 (or)
38+ (and)
34 (bang)
39 (bang)
35] @operator
40] @operator
36
41
@@ -47,13 +52,22 @@
47
52
48;; Types
53;; Types
49(record_field name: (wordy_id) @variable.other.member type: (wordy_id) @type)
54(record_field name: (wordy_id) @variable.other.member type: (wordy_id) @type)
50−[
55+(type_constructor (type_name (wordy_id) @constructor))
51− (type_name)
56+(ability_declaration type_name: (wordy_id) @type type_arg: (wordy_id) @variable.parameter)
52− (type_signature)
57+(effect (wordy_id) @special) ;; NOTE: an effect is just like a type, but in signature we special case it
53− (effect)
58+
54−] @type
59+;; Namespaces
60+(path) @namespace
61+(namespace) @namespace
62+
63+;; Terms
64+(type_signature term_name: (path)? @variable term_name: (wordy_id) @variable)
65+(type_signature (wordy_id) @type)
66+(type_signature (delayed (wordy_id)) @type)
67+
68+(term_definition param: (wordy_id) @variable.parameter)
55
69
56−(term_definition) @variable
70+(function_application function_name: (path)? function_name: (wordy_id) @function)
57
71
58;; Punctuation
72;; Punctuation
59[
73[
@@ -70,3 +84,4 @@
70 "]"
84 "]"
71] @punctuation.bracket
85] @punctuation.bracket
72
86
87+(test_watch_expression (wordy_id) @keyword.directive)