ci: fix wrong queries

This commit is contained in:
Thomas Vigouroux 2020-09-07 18:14:54 +02:00
parent 5d2b866518
commit b90e520ccd
10 changed files with 22 additions and 23 deletions

View file

@ -96,12 +96,12 @@
destination: (word) @parameter)
("$" (variable_name)) @identifier
("$" (variable_name)) @variable
(expansion
[ "${" "}" ] @punctuation.bracket)
(variable_name) @identifier
(variable_name) @variable
(case_item
value: (word) @parameter)

View file

@ -124,6 +124,6 @@
; Annotations (not fully supported by parser)
((ERROR) @annotation
(vim-match? @annotation "\[?\[.*\]\]?.*$"))
(attribute) @annotation
((ERROR) @attribute
(vim-match? @attribute "\[?\[.*\]\]?.*$"))
(attribute) @attribute

View file

@ -8,9 +8,9 @@
; Annotations
(annotation
name: (identifier) @annotation)
name: (identifier) @attribute)
(marker_annotation
name: (identifier) @annotation)
name: (identifier) @attribute)
; Operators and Tokens
@ -123,7 +123,7 @@
name: (identifier) @parameter)
(named_argument
(label (identifier) @variable.parameter))
(label (identifier) @parameter))
; Literals
@ -136,7 +136,7 @@
; (hex_floating_point_literal)
] @number
(symbol_literal) @string.special.symbol
(symbol_literal) @string.special
(string_literal) @string
(true) @boolean
(false) @boolean

View file

@ -121,7 +121,7 @@
(interpreted_string_literal) @string
(raw_string_literal) @string
(rune_literal) @string
(escape_sequence) @escape
(escape_sequence) @string.escape
(int_literal) @number
(float_literal) @float

View file

@ -41,24 +41,24 @@
;; Call references
((call_expression
function: (identifier) @reference) @call
function: (identifier) @reference)
(set! reference.kind "call" ))
((call_expression
function: (selector_expression
field: (field_identifier) @reference)) @call
field: (field_identifier) @reference))
(set! reference.kind "call" ))
((call_expression
function: (parenthesized_expression
(identifier) @reference)) @call
(identifier) @reference))
(set! reference.kind "call" ))
((call_expression
function: (parenthesized_expression
(selector_expression
field: (field_identifier) @reference))) @call
field: (field_identifier) @reference)))
(set! reference.kind "call" ))
;; Scopes

View file

@ -35,15 +35,14 @@
; Functions
(constructor_declaration) @scope
(method_declaration
name: (identifier) @definition.scope) @scope
(method_declaration) @scope
; DEFINITIONS
(package_declaration
(identifier) @definition.namespace)
(class_declaration
name: (identifier) @definition.class)
name: (identifier) @definition.type)
(enum_declaration
name: (identifier) @definition.enum)
(method_declaration

View file

@ -9,4 +9,4 @@
(jsx_opening_element name: (identifier) @variable.builtin)
(jsx_self_closing_element name: (identifier) @variable.builtin)
(jsx_text) @none
(jsx_text) @Normal

View file

@ -32,10 +32,10 @@
(namespace_use_clause
(qualified_name
(name) @definition.class))
(name) @definition.type))
(class_declaration
name: (name) @definition.class)
name: (name) @definition.type)
; References
;------------

View file

@ -67,11 +67,11 @@
(identifier) @type)) ; type subscript: Tuple[int]
((call
function: (identifier) @isinstance
function: (identifier) @_isinstance
arguments: (argument_list
(_)
(identifier) @type))
(#eq? @isinstance "isinstance"))
(#eq? @_isinstance "isinstance"))
; Normal parameters
(parameters

View file

@ -24,6 +24,6 @@
(end_assertion)
(boundary_assertion)
(non_boundary_assertion)
] @escape
] @string.escape
[ "*" "+" "|" "=" "<=" "!" "<!" ] @operator