Skip to content
This repository has been archived by the owner on Nov 4, 2024. It is now read-only.

Commit

Permalink
Move call grammar declaration
Browse files Browse the repository at this point in the history
  • Loading branch information
alxkzmn committed Aug 28, 2024
1 parent cce3de0 commit 9712c58
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/parser/chiquito.lalrpop
Original file line number Diff line number Diff line change
Expand Up @@ -116,10 +116,6 @@ HyperTransition: Statement<BigInt, Identifier> = {
<l: @L> <ids: ParseIdsList> "<==" <call:Expression> "->" <st: Identifier> <r: @R> => build_hyper_transition(dsym_factory.create(l,r), ids, call, st),
}

Call: Expression<BigInt, Identifier> = {
<l: @L> <fun: Identifier> "(" <es:ParseExpressionList> ")" <r: @R> => Expression::Call(dsym_factory.create(l,r), fun, es),
}

ParseSignalDecl: Statement<BigInt, Identifier> = {
<l: @L> "signal" <ids: ParseTypedIdList> <r: @R> => Statement::SignalDecl(dsym_factory.create(l,r), ids),
}
Expand Down Expand Up @@ -205,6 +201,10 @@ ParsePrefix: Expr = {
ExpressionTerm
}

Call: Expr = {
<l: @L> <fun: Identifier> "(" <es:ParseExpressionList> ")" <r: @R> => Expression::Call(dsym_factory.create(l,r), fun, es),
}

ExpressionTerm: Expr = {
<l: @L> <id: Identifier> <r: @R> => build_query(id, dsym_factory.create(l,r)),
<l: @L> <lit: FieldElement> <r: @R> => lit,
Expand Down

0 comments on commit 9712c58

Please sign in to comment.