Skip to content

Commit 24a9eae

Browse files
highlight calls to erlang modules as types (#5)
* highlight calls to erlang modules as types * Add test Co-authored-by: Jonatan Kłosko <[email protected]>
1 parent 7ae20df commit 24a9eae

File tree

2 files changed

+13
-0
lines changed

2 files changed

+13
-0
lines changed

queries/highlights.scm

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,10 @@
6464

6565
(alias) @type
6666

67+
(call
68+
target: (dot
69+
left: (atom) @type))
70+
6771
(char) @constant
6872

6973
; Quoted content

test/highlight/calls.ex

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -79,3 +79,12 @@ Enum.map([1, 2], fn x ->
7979
end)
8080
# <- keyword
8181
# ^ punctuation.bracket
82+
83+
:erlang.abs(-1)
84+
# ^ type
85+
# ^ operator
86+
# ^ function
87+
# ^ punctuation.bracket
88+
# ^ operator
89+
# ^ number
90+
# ^ punctuation.bracket

0 commit comments

Comments
 (0)