aboutsummaryrefslogtreecommitdiff
path: root/runtime/queries/dhall/highlights.scm
blob: 52ede31024667d5114b11a177c621ab1a4fc91dd (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
;; Literals

(integer_literal) @constant.numeric.integer
(natural_literal) @constant.numeric.integer
(double_literal) @constant.numeric.float
(boolean_literal) @constant.builtin.boolean
(text_literal) @string
(local_import) @string.special.path
(http_import) @string.special.url
(import_hash) @string

;; Comments
[
  (line_comment)
  (block_comment)
] @comment

;; Keywords
[
  ("let")
  ("in")
  (assign_operator)
  (type_operator)
  (lambda_operator)
  (arrow_operator)
  (infix_operator)
  (completion_operator)
  ("using")
  ("assert")
  (assert_operator)
  ("as")
  (forall_operator)
  ("with")
] @keyword

;; Builtins
[
  (builtin_function)
  (missing_import)
] @function.builtin

[ 
  (builtin)
  (import_as_text)
] @type.builtin

;; Conditionals
[
  ("if")
  ("then")
  ("else")
] @keyword.control.conditional