erlang: Fix highlighting of empty records

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.
This commit is contained in:
Michael Davis 2022-08-09 11:27:42 -05:00 committed by Blaž Hrastnik
parent acf3599723
commit ac669ade05

View File

@ -18,7 +18,7 @@
. .
[(atom) @type (macro)] [(atom) @type (macro)]
[ [
(tuple (atom) @variable.other.member) (tuple (atom)? @variable.other.member)
(tuple (tuple
(binary_operator (binary_operator
left: (atom) @variable.other.member left: (atom) @variable.other.member