diff --git a/data/Example3.circom b/data/Example3.circom index 509389b..a1bc4d0 100644 --- a/data/Example3.circom +++ b/data/Example3.circom @@ -1,4 +1,4 @@ -bus B1(){ +bus B1 { signal x; } diff --git a/grammar/CircomParser.g4 b/grammar/CircomParser.g4 index 77aa0e5..05644fe 100644 --- a/grammar/CircomParser.g4 +++ b/grammar/CircomParser.g4 @@ -44,10 +44,10 @@ blockDefiniton functionDefinition: 'function' ID '(' argNames=simpleIdentifierList? ')' body ; templateDefinition - : 'template' 'custom'? 'parallel'? ID '(' argNames=simpleIdentifierList? ')' body + : 'template' 'custom'? 'parallel'? ID ('(' argNames=simpleIdentifierList? ')')? body ; -busDefinition: 'bus' ID '(' argNames=simpleIdentifierList? ')' body ; +busDefinition: 'bus' ID ('(' argNames=simpleIdentifierList? ')')? body ; publicInputsDefinition: '{' 'public' '[' publicInputs=simpleIdentifierList ']' '}' ;