Skip to content

Commit

Permalink
fix: table types that are list-like
Browse files Browse the repository at this point in the history
  • Loading branch information
amaanq committed Jan 24, 2024
1 parent 5f9dcd4 commit f04cea4
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions grammar.js
Original file line number Diff line number Diff line change
Expand Up @@ -182,11 +182,12 @@ module.exports = grammar(lua, {

object_type: $ => seq(
'{',
commaSep1(seq(
choice($.identifier, $.object_field_type),
':',
$.type,
)),
choice(
commaSep1(
seq(choice($.identifier, $.object_field_type), ':', $.type),
),
commaSep1($.type),
),
optional(','),
'}',
),
Expand Down

0 comments on commit f04cea4

Please sign in to comment.