diff options
author | Michael Davis | 2022-04-17 17:46:22 +0000 |
---|---|---|
committer | GitHub | 2022-04-17 17:46:22 +0000 |
commit | ad36a024da4dae0cc096cae8ab83740507bc8d8a (patch) | |
tree | 5b1e3c6e535bc1be113314ca5190e2ac131722b6 /runtime/queries/erlang | |
parent | c45fb08a9389e21d9694059819aed940ba446a0b (diff) |
Update tree-sitters Erlang and HEEx (#2149)
Diffstat (limited to 'runtime/queries/erlang')
-rw-r--r-- | runtime/queries/erlang/highlights.scm | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/runtime/queries/erlang/highlights.scm b/runtime/queries/erlang/highlights.scm index 067e0f82..1e075349 100644 --- a/runtime/queries/erlang/highlights.scm +++ b/runtime/queries/erlang/highlights.scm @@ -48,8 +48,14 @@ (attribute name: (atom) @keyword + (arguments + (_) @keyword.directive) + (#match? @keyword "ifn?def")) + +(attribute + name: (atom) @keyword module: (atom) @module - (#eq? @keyword "spec")) + (#eq? @keyword "(spec|callback)")) ; Functions (function name: (atom) @function) @@ -69,10 +75,7 @@ (record name: (atom) @type) ; Keywords -((attribute name: (atom) @keyword) - (#match? - @keyword - "^(define|export|export_type|include|include_lib|ifdef|ifndef|if|elif|else|endif|vsn|on_load|behaviour|record|file|type|opaque|spec)$")) +(attribute name: (atom) @keyword) ["case" "fun" "if" "of" "when" "end" "receive" "try" "catch" "after" "begin" "maybe"] @keyword @@ -86,10 +89,6 @@ (unary_operator operator: _ @operator) ["/" ":" "#" "->"] @operator -; Comments -((variable) @comment.discard - (#match? @comment.discard "^_")) - (tripledot) @comment.discard (comment) @comment @@ -99,12 +98,13 @@ "?"+ @keyword.directive name: (_) @keyword.directive) +; Comments +((variable) @comment.discard + (#match? @comment.discard "^_")) + ; Basic types (variable) @variable -[ - (atom) - (quoted_atom) -] @string.special.symbol +(atom) @string.special.symbol (string) @string (character) @constant.character |