Add methods high-lighting

This commit is contained in:
Bruno BELANYI 2022-06-04 21:29:27 +02:00
parent 555e10c736
commit 425890a6fc
2 changed files with 10 additions and 1 deletions

View file

@ -75,7 +75,7 @@
] @punctuation.bracket
; }}}
; Functions {{{
; Functions and methods {{{
(function_call
function: (identifier) @function)
(function_declaration
@ -83,6 +83,11 @@
(primitive_declaration
name: (identifier) @function)
(method_call
method: (identifier) @method)
(method_declaration
name: (identifier) @method)
(parameters
name: (identifier) @variable.parameter)
; }}}

View file

@ -13,6 +13,7 @@ let
method meth() : int = self.a
/* <- keyword */
/* ^ method */
/* ^ variable */
}
@ -21,4 +22,7 @@ let
in
object.a := 27;
/* ^ property */
object.meth()
/* ^ method */
end