Skip to content

Commit

Permalink
erlang: Fix highlighting of empty records
Browse files Browse the repository at this point in the history
For example

    -record(state, {})

Would not highlight `state` as a type since the alternation didn't
allow for an empty tuple. Allowing the inner atom of the tuple to be
optional fixes this case.
  • Loading branch information
the-mikedavis authored and archseer committed Aug 31, 2022
1 parent acf3599 commit ac669ad
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion runtime/queries/erlang/highlights.scm
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
.
[(atom) @type (macro)]
[
(tuple (atom) @variable.other.member)
(tuple (atom)? @variable.other.member)
(tuple
(binary_operator
left: (atom) @variable.other.member
Expand Down

0 comments on commit ac669ad

Please sign in to comment.