chore(bicep): update queries and add scanner

This commit is contained in:
Amaan Qureshi 2024-02-02 00:12:17 -05:00 committed by Christian Clason
parent d2b4563230
commit 8b99311ca1
4 changed files with 29 additions and 15 deletions

View file

@ -22,6 +22,9 @@
(call_expression
function: (identifier) @function.call)
(user_defined_function
name: (identifier) @function)
; Properties
(object_property
(identifier) @property
@ -58,12 +61,6 @@
"="
(identifier) @type)
(type_declaration
(identifier)
"="
(array_type
(identifier) @type))
(type
(identifier) @type)
@ -89,6 +86,10 @@
(member_expression
object: (identifier) @variable.parameter)))
(parameter
.
(identifier) @variable.parameter)
; Variables
(variable_declaration
(identifier) @variable
@ -137,8 +138,14 @@
"targetScope"
"type"
"var"
"using"
"test"
] @keyword
"func" @keyword.function
"assert" @keyword.exception
; Operators
[
"+"
@ -160,19 +167,20 @@
"??"
"="
"!"
".?"
] @operator
(subscript_expression
"?" @operator)
(nullable_type
"?" @operator)
"in" @keyword.operator
; Literals
(string) @string
(import_string
"'" @string
(import_name) @module
"@" @string.special.symbol
(import_version) @string.special)
(escape_sequence) @string.escape
(number) @number
@ -204,6 +212,7 @@
[
"."
":"
"::"
"=>"
] @punctuation.delimiter

View file

@ -36,7 +36,8 @@
(compatible_identifier) @local.definition.field
(_))
(import_name) @local.definition.import
(user_defined_function
name: (identifier) @local.definition.function)
(module_declaration
(identifier) @local.definition.namespace)
@ -45,6 +46,10 @@
(identifier) @local.definition.parameter
(_))
(parameter
.
(identifier) @local.definition.parameter)
(type_declaration
(identifier) @local.definition.type
(_))