-
Notifications
You must be signed in to change notification settings - Fork 39
Parse HyperTransition syntax #295
Parse HyperTransition syntax #295
Conversation
@@ -37,9 +37,9 @@ pub Statements: Vec<Statement<BigInt, Identifier>> = { | |||
} | |||
|
|||
ParseStatement: Statement<BigInt, Identifier> = { | |||
<l: @L> <s: StatementType> ";" <r: @R> => add_dsym(dsym_factory.create(l,r), s), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Each statement type already has its own L and R parsing, so add_dsym
wasn't needed anymore.
src/parser/chiquito.lalrpop
Outdated
} | ||
|
||
Call: Statement<BigInt, Identifier> = { | ||
<l: @L> <ids: ParseIdsList> "<==" <machine: Identifier> "(" <es:ParseExpressionList> ")" <r: @R> => Statement::Call(dsym_factory.create(l,r), ids, machine, es), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As a call can be part of an expression in general, probably in the future when we implement actual function calls, it should be an Expression and not an statement @alxkzmn
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Got it, will implement.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There are some todos, that we should put in issues if they are not already. Perhaps you can put that they need spec'ing :-)
Approved
No description provided.