Unnamed repository; edit this file 'description' to name the repository.
| -rw-r--r-- | runtime/queries/erlang/highlights.scm | 6 | ||||
| -rw-r--r-- | runtime/queries/erlang/locals.scm | 4 |
2 files changed, 5 insertions, 5 deletions
diff --git a/runtime/queries/erlang/highlights.scm b/runtime/queries/erlang/highlights.scm index 769a7e96..64e5f6a1 100644 --- a/runtime/queries/erlang/highlights.scm +++ b/runtime/queries/erlang/highlights.scm @@ -7,7 +7,7 @@ (variable) @variable (atom) @string.special.symbol ((atom) @constant.builtin.boolean - (#match? @constant.builtin.boolean "^(true|false)$")) + (#any-of? @constant.builtin.boolean "true" "false")) [(string) (sigil)] @string (character) @constant.character (escape_sequence) @constant.character.escape @@ -121,7 +121,7 @@ (stab_clause pattern: (arguments (variable)? @variable.parameter) body: (variable)? @variable.parameter)) - (#match? @keyword "(spec|callback)")) + (#any-of? @keyword "spec" "callback")) ; functions (function_clause pattern: (arguments (variable) @variable.parameter)) ; anonymous functions @@ -133,7 +133,7 @@ (binary_operator left: (call (arguments (variable) @variable.parameter)) operator: "::"))) - (#match? @keyword "(type|opaque)")) + (#any-of? @keyword "type" "opaque" "nominal")) ; macros ((attribute name: (atom) @keyword diff --git a/runtime/queries/erlang/locals.scm b/runtime/queries/erlang/locals.scm index e2212cac..c17d50a4 100644 --- a/runtime/queries/erlang/locals.scm +++ b/runtime/queries/erlang/locals.scm @@ -7,12 +7,12 @@ ; parametric `-type`s ((attribute - name: (atom) @_type + name: (atom) @keyword (arguments (binary_operator left: (call (arguments (variable) @local.definition.variable.parameter)) operator: "::") @local.scope)) - (#match? @_type "(type|opaque)")) + (#any-of? @keyword "type" "opaque" "nominal")) ; `fun`s (anonymous_function (stab_clause pattern: (arguments (variable) @local.definition.variable.parameter))) @local.scope |