Skip to content

Commit 8023833

Browse files
committed
Update queries to use new syntax
1 parent a8b5bc0 commit 8023833

File tree

2 files changed

+8
-8
lines changed

2 files changed

+8
-8
lines changed

queries/highlights.scm

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,20 +2,20 @@
22

33
; Assume all-caps names are constants
44
((identifier) @constant
5-
(match? @constant "^[A-Z][A-Z\\d_]+$'"))
5+
(#match? @constant "^[A-Z][A-Z\\d_]+$'"))
66

77
; Assume that uppercase names in paths are types
88
((scoped_identifier
99
path: (identifier) @type)
10-
(match? @type "^[A-Z]"))
10+
(#match? @type "^[A-Z]"))
1111
((scoped_identifier
1212
path: (scoped_identifier
1313
name: (identifier) @type))
14-
(match? @type "^[A-Z]"))
14+
(#match? @type "^[A-Z]"))
1515

1616
; Assume other uppercase names are enum constructors
1717
((identifier) @constructor
18-
(match? @constructor "^[A-Z]"))
18+
(#match? @constructor "^[A-Z]"))
1919

2020
; Function calls
2121

queries/injections.scm

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
((macro_invocation
22
(token_tree) @injection.content)
3-
(set! injection.language "rust")
4-
(set! injection.include-children))
3+
(#set! injection.language "rust")
4+
(#set! injection.include-children))
55

66
((macro_rule
77
(token_tree) @injection.content)
8-
(set! injection.language "rust")
9-
(set! injection.include-children))
8+
(#set! injection.language "rust")
9+
(#set! injection.include-children))

0 commit comments

Comments
 (0)