mirror of https://github.com/helix-editor/helix
queries: Fix `comment.unused` highlights in Erlang
* Other languages use `comment.unused` instead of `comment.discard`. * Fix the precedence of discarded variables - previously the parameter highlight was higher precedence so discarded variables in the parameter list were highlighted as parameters instead of `comment.unused`.pull/13460/head
parent
aa3fad84ef
commit
12139a4c30
|
@ -1,5 +1,5 @@
|
|||
; Comments
|
||||
(tripledot) @comment.discard
|
||||
(tripledot) @comment.unused
|
||||
|
||||
[(comment) (line_comment) (shebang)] @comment
|
||||
|
||||
|
@ -114,10 +114,6 @@
|
|||
] @comment.block.documentation)
|
||||
(#any-of? @keyword "doc" "moduledoc"))
|
||||
|
||||
; Ignored variables
|
||||
((variable) @comment.discard
|
||||
(#match? @comment.discard "^_"))
|
||||
|
||||
; Macros
|
||||
(macro
|
||||
"?"+ @keyword.directive
|
||||
|
@ -163,3 +159,7 @@
|
|||
|
||||
(record field: (atom) @variable.other.member)
|
||||
(record name: (atom) @type)
|
||||
|
||||
; Ignored variables
|
||||
((variable) @comment.unused
|
||||
(#match? @comment.unused "^_"))
|
||||
|
|
Loading…
Reference in New Issue