Skip to content
This repository was archived by the owner on Jun 2, 2025. It is now read-only.

Commit c45f5e2

Browse files
author
Mickey Reiss
committed
Fix bug in parser grammar
1 parent af999ae commit c45f5e2

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

internal/ast/parser.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,10 +61,10 @@ type AST struct {
6161

6262
type ASTElement struct {
6363
Comment string `parser:"{ @Comment }"`
64-
Model *ASTModel `parser:" 'model' @@"`
64+
Model *ASTModel `parser:"( 'model' @@"`
6565
Enum *ASTEnum `parser:"| 'enum' @@"`
6666
Option *ASTOption `parser:"| 'option' @@"`
67-
Struct *ASTStruct `parser:"| 'struct' @@"`
67+
Struct *ASTStruct `parser:"| 'struct' @@ )"`
6868
}
6969

7070
type ASTModel struct {

0 commit comments

Comments
 (0)