Locals matching "when" operator, add pipe queries

This commit is contained in:
Connor Lay (Clay) 2021-10-08 13:26:46 -07:00 committed by Stephan Seitz
parent 25b28f6185
commit 725ef8fc18
2 changed files with 95 additions and 62 deletions

View file

@ -86,16 +86,16 @@
(stab_clause
operator: _ @operator)
; Calling a local function
; Local Function Calls
(call target: (identifier) @function)
; Calling a remote function
; Remove Function Calls
(call target: (dot left: [
(atom) @type
(_)
] right: (identifier) @function) (arguments))
; Calling a local def function
; Definition Function Calls
(call target: ((identifier) @keyword.function (#any-of? @keyword.function
"def"
"defdelegate"
@ -142,7 +142,7 @@
"with"
)))
; Special constants
; Special Constants
((identifier) @constant.builtin (#any-of? @constant.builtin
"__CALLER__"
"__DIR__"
@ -182,6 +182,11 @@
)
])
; Pipe Operator
(binary_operator
operator: "|>"
right: (identifier) @function)
; Module attributes
(unary_operator
operator: "@" @constant