Skip to content

Commit

Permalink
feat: support more diverse grammar
Browse files Browse the repository at this point in the history
  • Loading branch information
Devin-Yeung committed Nov 17, 2024
1 parent 6c404e8 commit 08c5803
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/parser.lalrpop
Original file line number Diff line number Diff line change
Expand Up @@ -88,14 +88,14 @@ Alternative: Alternative = {
}
},

<l: @L> <symbols: Symbol+> "{" <lo: "int"> <comma: ","?> <hi: "int"?> "}" <r: @R> => {
<l: @L> <weight: "int"?> <symbols: Symbol+> "{" <lo: "int"> <comma: ","?> <hi: "int"?> "}" <r: @R> => {
Alternative {
span: Span::new(l, r),
invoke_limit: Limit::Limited {
min: lo,
max: hi.unwrap_or(lo),
},
weight: 1,
weight: weight.unwrap_or(1),
symbols,
}
},
Expand Down

0 comments on commit 08c5803

Please sign in to comment.